:root {
  --ink: #15110d;
  --paper: #f3efe7;
  --card: #fffaf0;
  --muted: #6d6257;
  --line: #dfd5c4;
  --gold: #d9a13b;
  --tomato: #b93625;
  --leaf: #195b3a;
  --char: #1f140f;
  --shadow: 0 22px 60px rgba(28, 18, 10, 0.18);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(115deg, rgba(21, 17, 13, 0.08), transparent 32rem),
    radial-gradient(circle at 88% 4%, rgba(217, 161, 59, 0.18), transparent 20rem),
    repeating-linear-gradient(90deg, rgba(23, 17, 13, 0.025) 0 1px, transparent 1px 22px),
    var(--paper);
  font-family: "Segoe UI", "Aptos", sans-serif;
  overflow-x: hidden;
}

a { color: inherit; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  gap: 1rem;
  align-items: center;
  padding: 0.8rem clamp(1rem, 4vw, 2.5rem);
  background: rgba(243, 239, 231, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  gap: 0.75rem;
  align-items: center;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 48px;
  aspect-ratio: 1;
  place-items: center;
  border: 3px solid var(--ink);
  border-radius: 8px;
  background: #15110d;
  color: var(--gold);
  font-weight: 900;
}

.brand strong, .brand small { display: block; }
.brand small { color: var(--muted); }

.nav {
  display: flex;
  gap: 1rem;
  font-weight: 800;
}

.nav a {
  text-decoration: none;
  color: var(--muted);
}

.call-chip {
  padding: 0.75rem 1rem;
  border-radius: 999px;
  color: #fff;
  background: var(--ink);
  text-decoration: none;
  font-weight: 900;
}

.nav-bell {
  position: relative;
  display: inline-grid;
  min-width: 48px;
  min-height: 48px;
  place-items: center;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--gold);
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-size: 0.65rem;
  font-weight: 1000;
  box-shadow: 3px 3px 0 var(--ink);
}

.nav-bell span {
  position: relative;
  width: 18px;
  height: 21px;
  border: 3px solid var(--ink);
  border-bottom: 0;
  border-radius: 12px 12px 5px 5px;
}

.nav-bell span::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -7px;
  width: 8px;
  height: 6px;
  border: 3px solid var(--ink);
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  transform: translateX(-50%);
}

.nav-bell span::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -7px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ink);
  transform: translateX(-50%);
}

.nav-bell strong {
  position: absolute;
  top: -0.55rem;
  right: -0.4rem;
  min-width: 1.55rem;
  min-height: 1.55rem;
  display: grid;
  place-items: center;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--tomato);
  color: #fff;
  font-size: 0.78rem;
}

.hero {
  min-height: calc(100vh - 76px);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(20rem, 0.75fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
  padding: clamp(2rem, 6vw, 5rem) clamp(1rem, 5vw, 5rem);
}

.hero-copy {
  min-width: 0;
}

.eyebrow {
  margin: 0 0 0.8rem;
  color: var(--tomato);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 1rem;
  font-size: clamp(4rem, 11vw, 9rem);
  line-height: 0.82;
  letter-spacing: 0;
  text-transform: none;
  font-family: Georgia, "Times New Roman", serif;
}

h2 {
  margin-bottom: 1rem;
  font-size: clamp(2rem, 5vw, 4.5rem);
  line-height: 0.95;
  letter-spacing: 0;
  font-family: Georgia, "Times New Roman", serif;
}

h3 { font-size: 1.2rem; }

.lead {
  max-width: 42rem;
  color: #4f453c;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  line-height: 1.55;
}

.hero-actions,
.category-tabs,
.cart-row,
.admin-card-head,
.lookup-form,
.inline-form {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.button,
.icon-button,
.text-button {
  border: 0;
  cursor: pointer;
  font: inherit;
  font-weight: 900;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.2rem;
  border: 2px solid var(--ink);
  border-radius: 6px;
  text-decoration: none;
  box-shadow: 5px 5px 0 var(--ink);
}

.button.primary { background: var(--gold); color: var(--ink); }
.button.dark { background: var(--ink); color: #fff; }
.button.ghost { background: #fff; color: var(--ink); }
.button.full { width: 100%; }
.button.compact {
  min-height: 36px;
  padding: 0.45rem 0.8rem;
  box-shadow: 3px 3px 0 var(--ink);
}

.danger-button {
  color: var(--tomato);
  background: #ffe8e2;
}

.proof-grid {
  display: grid;
  max-width: 48rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 2rem 0 0;
}

.store-status {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin: 0.5rem 0 1.25rem;
  padding: 0.8rem 1rem;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
  font-weight: 900;
}

.store-status span:last-child {
  color: var(--muted);
  font-weight: 800;
}

.status-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--tomato);
}

.store-status.open .status-dot {
  background: var(--leaf);
}

.proof-grid div {
  padding: 1rem;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.62);
}

.proof-grid dt {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
}

.proof-grid dd {
  margin: 0.3rem 0 0;
  font-size: 1.1rem;
  font-weight: 900;
}

.hero-visual {
  position: relative;
  min-height: 34rem;
  overflow: hidden;
  border: 1px solid rgba(21, 17, 13, 0.18);
  background: #17110d;
  box-shadow: var(--shadow);
}

.hero-visual img {
  width: 100%;
  height: 100%;
  min-height: 34rem;
  object-fit: cover;
  display: block;
}

.hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 46%, rgba(0, 0, 0, 0.54));
  pointer-events: none;
}

.photo-badge {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  z-index: 2;
  display: grid;
  gap: 0.1rem;
  padding: 0.9rem 1rem;
  color: #fff8e9;
  background: rgba(21, 17, 13, 0.82);
  border-left: 4px solid var(--gold);
}

.photo-badge strong {
  font-size: 1.15rem;
}

.photo-badge span {
  color: #dbcab3;
  font-weight: 800;
}

.order-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(22rem, 0.36fr);
  gap: 1rem;
  padding: clamp(1rem, 4vw, 3rem);
}

.menu-panel,
.cart-panel,
.customer-service-grid,
.customer-portal-section,
.customer-check-card,
.admin-login,
.dashboard,
.footer {
  border-top: 5px solid var(--ink);
  background: var(--card);
  box-shadow: var(--shadow);
}

.menu-panel,
.customer-service-grid,
.customer-portal-section,
.customer-check-card,
.admin-login,
.dashboard {
  padding: clamp(1rem, 3vw, 2rem);
}

.cart-panel {
  position: sticky;
  top: 96px;
  align-self: start;
  padding: 1rem;
}

.toolbar {
  display: grid;
  gap: 1rem;
  margin: 1rem 0;
}

input, select, textarea {
  width: 100%;
  min-height: 46px;
  padding: 0.75rem;
  border: 2px solid var(--line);
  border-radius: 4px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

label {
  display: grid;
  gap: 0.4rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 900;
}

.category-tabs button {
  min-height: 40px;
  padding: 0.6rem 0.85rem;
  border: 2px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-weight: 900;
}

.category-tabs button.active {
  border-color: var(--ink);
  color: var(--ink);
  background: var(--gold);
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: 0.8rem;
}

.menu-card {
  display: grid;
  gap: 0.75rem;
  padding: 1rem;
  border: 1px solid var(--line);
  background: #fff;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.menu-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(28, 18, 10, 0.11);
}

.menu-photo {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
  border: 1px solid var(--line);
  background: #eee4d5;
}

.menu-card strong {
  display: block;
  font-size: 1.05rem;
}

.menu-card p {
  min-height: 3.4rem;
  margin: 0;
  color: var(--muted);
  line-height: 1.4;
}

.price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

.price {
  font-size: 1.25rem;
  font-weight: 900;
}

.add-button {
  min-width: 44px;
  height: 44px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  font-size: 1.2rem;
  font-weight: 900;
}

.cart-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: start;
}

.icon-button,
.text-button {
  min-height: 36px;
  padding: 0.45rem 0.7rem;
  border-radius: 4px;
  background: #f3ead8;
  color: var(--ink);
}

.cart-items {
  display: grid;
  gap: 0.55rem;
  min-height: 3rem;
  margin: 1rem 0;
}

.cart-items .cart-menu-row {
  display: grid !important;
  grid-template-columns: 56px minmax(0, 1fr) auto;
  justify-content: stretch !important;
  align-items: center !important;
  gap: 0.75rem;
  padding: 0.75rem;
  border: 1px solid var(--line);
  background: #fff;
}

.cart-menu-row .cart-item-copy {
  min-width: 0;
}

.cart-menu-row .cart-item-copy strong {
  display: block;
  text-align: left;
  overflow-wrap: anywhere;
  line-height: 1.2;
}

.cart-menu-row .cart-item-actions {
  display: flex;
  gap: 0.35rem;
  justify-content: flex-end;
}

.cart-thumb {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border: 1px solid var(--line);
  background: #eee4d5;
}

.cart-row button {
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  background: var(--paper);
  font-weight: 900;
}

.checkout-form,
.stack-form {
  display: grid;
  gap: 0.8rem;
}

.time-grid,
.schedule-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.schedule-row {
  grid-template-columns: minmax(8rem, 1fr) minmax(8rem, 1fr) minmax(8rem, 1fr);
  align-items: end;
  padding: 0.75rem;
  border: 1px solid var(--line);
  background: #fffaf0;
}

.schedule-editor {
  display: grid;
  gap: 0.55rem;
  margin-top: 0.7rem;
}

.form-note {
  margin: 0.35rem 0 0;
  color: var(--muted);
}

.redeem-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.redeem-row input {
  width: 20px;
  min-height: 20px;
}

.redeem-row:has(input:disabled) {
  color: var(--muted);
  opacity: 0.65;
}

.customer-point-panel {
  padding: 0.8rem;
  border: 1px solid var(--line);
  background: #fffaf0;
  color: var(--muted);
  font-weight: 800;
}

.customer-point-panel.loading {
  border-color: var(--gold);
  background: #fff4d8;
}

.customer-point-panel.found,
.customer-point-panel.eligible {
  color: var(--ink);
}

.customer-point-panel.eligible {
  border-color: var(--leaf);
  background: #edf7ef;
}

.customer-point-panel.new {
  background: #fff;
}

.totals {
  display: grid;
  gap: 0.35rem;
  padding: 1rem;
  background: #f5ead5;
}

.totals div {
  display: flex;
  justify-content: space-between;
}

.totals-note {
  margin: 0.25rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.customer-service-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: clamp(1rem, 4vw, 3rem);
  border-top: 0;
  background: transparent;
  box-shadow: none;
}

.customer-portal-section {
  margin: clamp(1rem, 4vw, 3rem);
}

.customer-portal-card {
  max-width: 78rem;
  margin: 0 auto;
  min-height: auto;
}

.customer-portal-card h2 {
  max-width: none;
}

.customer-dashboard {
  margin-top: 0.5rem;
}

.customer-profile-card {
  display: grid;
  gap: 1rem;
}

.customer-profile-head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: start;
}

.customer-profile-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.customer-profile-stats div {
  padding: 1rem;
  border: 1px solid var(--line);
  background: var(--paper);
}

.customer-profile-stats span {
  display: block;
  color: var(--muted);
  font-weight: 900;
}

.customer-profile-stats strong {
  font-size: 1.4rem;
}

.customer-password-form {
  max-width: 34rem;
}

.customer-order-list {
  display: grid;
  gap: 0.75rem;
}

.customer-check-card {
  display: grid;
  grid-template-rows: auto auto 1fr;
  gap: 1.15rem;
  min-height: 22rem;
  align-content: stretch;
}

.customer-check-card h2 {
  max-width: 15ch;
  font-size: clamp(2.6rem, 4.1vw, 4.25rem);
  text-wrap: balance;
}

.customer-check-card p:not(.eyebrow) {
  max-width: 48rem;
  line-height: 1.55;
}

.customer-check-card .lookup-form {
  align-self: start;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
}

.secure-lookup-form {
  align-items: stretch;
}

.secure-lookup-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(8rem, 0.45fr);
  gap: 0.55rem;
}

.secure-lookup-fields input {
  min-height: 54px;
}

.secure-lookup-form .button {
  min-width: 9.5rem;
}

.lookup-form input {
  width: 100%;
  flex: 1 1 14rem;
}

.lookup-result {
  display: grid;
  gap: 0.75rem;
}

.admin-shell {
  padding: clamp(1rem, 4vw, 3rem);
}

.admin-page h1 {
  font-size: clamp(2.6rem, 7vw, 5.6rem);
}

.admin-login {
  max-width: 36rem;
  margin: auto;
}

.forgot-password-form,
.admin-recovery-form {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.hidden { display: none !important; }

.dashboard-head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: start;
}

.profile-form {
  max-width: 34rem;
}

.dashboard-layout {
  display: grid;
  grid-template-columns: 14rem minmax(0, 1fr);
  gap: 1rem;
}

.dashboard-sidebar {
  position: sticky;
  top: 96px;
  align-self: start;
  display: grid;
  gap: 0.55rem;
  padding: 1rem;
  border: 1px solid var(--line);
  background: #fff;
}

.side-link {
  min-height: 44px;
  padding: 0.75rem;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  text-align: left;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.side-link.active {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff8e9;
}

.admin-section {
  display: none;
}

.admin-section.active {
  display: block;
}

.stats-grid,
.dashboard-grid {
  display: grid;
  gap: 1rem;
}

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

.order-alert {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  margin: 0 0 1rem;
  padding: 1rem;
  border: 2px solid var(--tomato);
  background: #fff0dc;
  box-shadow: 5px 5px 0 var(--ink);
}

.order-alert p {
  margin: 0.25rem 0 0;
}

.bell-wrap {
  position: relative;
  display: grid;
  width: 64px;
  aspect-ratio: 1;
  place-items: center;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--gold);
  color: var(--ink);
  font-size: 0.65rem;
  font-weight: 1000;
}

.bell-count {
  position: absolute;
  top: -0.55rem;
  right: -0.45rem;
  min-width: 1.6rem;
  min-height: 1.6rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  border: 2px solid var(--ink);
  background: var(--tomato);
  color: #fff;
  font-size: 0.8rem;
}

.alert-copy {
  flex: 1;
}

.activity-feed {
  display: grid;
  gap: 0.45rem;
  margin-top: 0.75rem;
}

.activity-row {
  position: relative;
  display: grid;
  gap: 0.15rem;
  padding: 0.65rem 2.4rem 0.65rem 0.65rem;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
}

.activity-delete {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  width: 1.65rem;
  height: 1.65rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  background: var(--cream);
  color: var(--ink);
  font-weight: 1000;
  cursor: pointer;
}

.activity-row.redeem {
  border-left: 5px solid var(--tomato);
}

.activity-row.order {
  border-left: 5px solid var(--leaf);
}

.activity-row.payment,
.activity-row.status,
.activity-row.delete {
  border-left: 5px solid var(--gold);
}

.activity-row.delete {
  border-left-color: var(--tomato);
}

.activity-row small {
  color: var(--muted);
}

.pill.danger {
  background: #ffe1dc;
  color: var(--tomato);
}

.pill.paid {
  background: #edf7ef;
  color: var(--leaf);
}

.pill.pending {
  background: #fff4d8;
  color: #8a5a00;
}

.pill.cancel {
  background: #ffe1dc;
  color: var(--tomato);
}

.status-card {
  display: grid;
  gap: 0.35rem;
  padding: 1rem;
  border: 1px solid var(--line);
  background: #fff;
}

select {
  max-width: 100%;
}

.stat-card,
.admin-card,
.customer-record,
.lookup-card {
  border: 1px solid var(--line);
  background: #fff;
}

.stat-card { padding: 1rem; }
.stat-card strong { display: block; font-size: 1.8rem; }
.stat-card span { color: var(--muted); font-weight: 900; }

.admin-card {
  padding: 1rem;
}

.admin-card.wide {
  grid-column: 1 / -1;
}

.orders-card {
  grid-column: 1 / -1;
}

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

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  padding: 0.75rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.customer-list,
.lookup-result,
.product-list {
  display: grid;
  gap: 0.75rem;
}

.customer-record,
.lookup-card,
.product-record {
  padding: 1rem;
}

.customer-reset-form {
  margin: 0.75rem 0;
}

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

.product-manager {
  padding: clamp(1rem, 2vw, 1.35rem);
}

.product-record {
  display: grid;
  gap: 0.6rem;
  border: 1px solid var(--line);
  background: #fff;
}

.product-record p,
.product-record-actions {
  grid-column: auto;
}

.product-thumb {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--line);
  background: #eee4d5;
}

.profit-preview {
  padding: 0.75rem;
  border-left: 4px solid var(--gold);
  background: #f4ead8;
  font-weight: 900;
}

.image-control {
  display: grid;
  gap: 0.65rem;
}

.image-preview {
  display: grid;
  min-height: 180px;
  place-items: center;
  border: 1px dashed var(--line);
  background: #f5ecdf;
  color: var(--muted);
  font-weight: 900;
  overflow: hidden;
}

.image-preview img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

.upload-button {
  display: inline-flex;
  width: fit-content;
  min-height: 42px;
  align-items: center;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--ink);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
}

.upload-button input {
  display: none;
}

.image-control small {
  color: var(--muted);
  font-weight: 800;
}

.toggle-row {
  display: flex;
  align-items: center;
}

.toggle-row input {
  width: 22px;
  min-height: 22px;
}

.extra-details {
  display: grid;
  gap: 0.55rem;
}

.detail-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.5rem;
}

.detail-row button {
  min-width: 42px;
  border: 1px solid var(--line);
  background: var(--paper);
  font-weight: 900;
}

.report-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 0.45fr);
  gap: 1rem;
}

.ranking-list,
.sales-summary {
  display: grid;
  gap: 0.6rem;
}

.ranking-row,
.sales-card {
  padding: 0.85rem;
  border: 1px solid var(--line);
  background: #fff;
}

.ranking-row {
  display: grid;
  grid-template-columns: 2.5rem minmax(0, 1fr) auto;
  gap: 0.7rem;
  align-items: center;
}

.ranking-row strong {
  display: block;
}

.confirm-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(21, 17, 13, 0.54);
}

.confirm-card {
  width: min(32rem, 100%);
  padding: 1.25rem;
  border-top: 5px solid var(--ink);
  background: var(--card);
  box-shadow: var(--shadow);
}

.product-record-actions,
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.product-record-actions button {
  min-height: 34px;
  padding: 0.4rem 0.7rem;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  font-weight: 900;
}

.pill {
  display: inline-flex;
  margin: 0.2rem 0.2rem 0 0;
  padding: 0.35rem 0.55rem;
  border-radius: 999px;
  background: #f4ead8;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: start;
  margin: clamp(1rem, 4vw, 3rem);
  padding: 1.5rem;
  background: var(--char);
  color: #fff7e6;
}

.footer p { margin: 0.35rem 0 0; color: #dccfbc; }

.toast {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 30;
  max-width: 24rem;
  padding: 1rem;
  border: 2px solid var(--ink);
  background: var(--gold);
  box-shadow: 5px 5px 0 var(--ink);
  font-weight: 900;
  transform: translateY(140%);
  transition: transform 180ms ease;
}

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

@media (max-width: 920px) {
  .topbar {
    grid-template-columns: 1fr auto;
  }

  .nav {
    grid-column: 1 / -1;
    order: 3;
  }

  .hero,
  .order-shell,
  .customer-service-grid,
  .dashboard-grid,
  .dashboard-layout,
  .report-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-sidebar {
    position: static;
  }

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

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

  .customer-check-card {
    grid-template-rows: auto;
    min-height: 0;
  }

  .hero {
    min-height: auto;
  }

  .cart-panel {
    position: static;
  }

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

@media (max-width: 560px) {
  .topbar {
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 0.7rem;
  }

  .brand-mark {
    width: 42px;
  }

  .call-chip {
    justify-self: start;
    padding: 0.65rem 0.75rem;
    font-size: 0.86rem;
  }

  .nav {
    width: 100%;
    justify-content: flex-start;
    gap: 0.5rem;
    font-size: 0.92rem;
  }

  .nav a {
    overflow-wrap: anywhere;
  }

  .customer-check-card .lookup-form {
    grid-template-columns: 1fr;
  }

  .secure-lookup-fields {
    grid-template-columns: 1fr;
  }

  .secure-lookup-form .button {
    width: 100%;
  }

  .customer-profile-head {
    display: grid;
  }

  .customer-profile-stats {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: clamp(3.2rem, 17vw, 5rem);
  }

  .hero {
    padding-inline: 1rem;
    overflow: hidden;
  }

  .hero-copy {
    width: min(100%, calc(100vw - 2rem));
  }

  .lead {
    width: min(100%, calc(100vw - 2rem));
    max-width: 21rem;
    font-size: 1rem;
    overflow-wrap: anywhere;
  }

  .store-status {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
  }

  .store-status span:last-child {
    grid-column: 1 / -1;
  }

  .proof-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    min-height: 20rem;
  }

  .footer,
  .dashboard-head {
    display: grid;
  }

  .product-list {
    grid-template-columns: 1fr;
  }

  .time-grid,
  .schedule-row,
  .order-alert {
    grid-template-columns: 1fr;
  }

  .order-alert {
    display: grid;
  }

  .admin-page {
    overflow-x: hidden;
  }

  .admin-shell {
    padding-inline: 0.75rem;
  }

  .dashboard-main,
  .admin-card,
  .table-wrap {
    min-width: 0;
  }

  .table-wrap {
    overflow: visible;
  }

  table,
  thead,
  tbody,
  tr,
  th,
  td {
    display: block;
    width: 100%;
  }

  thead {
    display: none;
  }

  tbody tr {
    margin-bottom: 1rem;
    padding: 0.85rem;
    border: 1px solid var(--line);
    background: #fff;
  }

  tbody td {
    display: grid;
    grid-template-columns: minmax(6.4rem, 34%) minmax(0, 1fr);
    gap: 0.75rem;
    align-items: start;
    padding: 0.55rem 0;
    border-bottom: 1px solid rgba(214, 198, 172, 0.65);
    overflow-wrap: anywhere;
  }

  tbody td:last-child {
    border-bottom: 0;
  }

  tbody td::before {
    content: attr(data-label);
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 1000;
    text-transform: uppercase;
  }

  tbody td select,
  tbody td button {
    width: 100%;
  }
}
