:root {
  --bg: #f5f7f2;
  --surface: #ffffff;
  --surface-tint: #edf6f4;
  --ink: #1d2622;
  --muted: #68736d;
  --line: #dce4dd;
  --brand: #c94832;
  --brand-dark: #8f2f22;
  --forest: #1f6f5b;
  --blue: #285f8f;
  --gold: #b78b23;
  --danger: #bd2d2d;
  --shadow: 0 18px 48px rgba(28, 48, 41, 0.1);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
}

body {
  background:
    linear-gradient(180deg, rgba(237, 246, 244, 0.9), rgba(245, 247, 242, 0) 320px),
    var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

body.has-lightbox {
  overflow: hidden;
}

a {
  color: inherit;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

button,
input,
select,
textarea {
  min-width: 0;
  font: inherit;
}

button {
  cursor: pointer;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  padding: 10px 11px;
  outline: none;
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--forest);
  box-shadow: 0 0 0 3px rgba(31, 111, 91, 0.14);
}

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

h1 {
  margin-bottom: 4px;
  font-size: 26px;
  line-height: 1.15;
}

h2 {
  margin-bottom: 12px;
  font-size: 18px;
  line-height: 1.25;
}

h3 {
  margin-bottom: 6px;
  font-size: 16px;
  line-height: 1.25;
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

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

th {
  background: #f0f4f2;
  color: #32453e;
  font-size: 12px;
  letter-spacing: 0;
  text-transform: uppercase;
}

td input,
td select,
td textarea {
  min-width: 132px;
  padding: 8px 9px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid rgba(220, 228, 221, 0.9);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(18px);
}

.topbar-inner {
  width: min(1180px, calc(100% - 28px));
  min-height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand img {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  object-fit: cover;
}

.brand span {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.brand strong {
  overflow-wrap: anywhere;
  font-size: 18px;
  line-height: 1.15;
}

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

.brand small,
.muted,
.eyebrow {
  font-size: 13px;
}

.container,
.page-grid {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
}

.container {
  padding: 24px 0;
}

.page-grid {
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 22px 0 calc(108px + env(safe-area-inset-bottom, 0px));
}

.stack,
.form-stack {
  display: grid;
  gap: 14px;
  align-content: start;
}

.panel {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 1px 0 rgba(20, 37, 31, 0.04);
  padding: 16px;
}

.panel-title,
.section-head,
.page-head,
.toolbar {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.panel-title,
.section-head,
.page-head {
  justify-content: space-between;
}

.page-head {
  margin-bottom: 16px;
}

.page-head > div,
.section-head > div,
.panel-title > div {
  min-width: 0;
}

.panel-title h1,
.section-head h2,
.page-head h1 {
  margin-bottom: 0;
}

.toolbar {
  flex-wrap: wrap;
}

.toolbar input,
.toolbar select {
  width: auto;
  min-width: 0;
}

.locale-field {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.locale-field select {
  min-height: 38px;
  padding: 7px 28px 7px 9px;
}

.event-list,
.menu-list,
.card-list {
  display: grid;
  gap: 10px;
}

.event-selection-panel .panel-title {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.event-selection-panel .panel-title h1 {
  white-space: nowrap;
  font-size: 24px;
}

.event-selection-panel .panel-title input {
  width: min(100%, 220px);
  justify-self: end;
}

.event-card {
  width: 100%;
  min-height: 92px;
  display: grid;
  gap: 3px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  padding: 12px;
  text-align: left;
}

.event-card span,
.event-card small {
  overflow-wrap: anywhere;
}

.event-card small {
  color: var(--muted);
}

.event-card.active,
tr.is-selected td {
  border-color: rgba(31, 111, 91, 0.38);
  background: var(--surface-tint);
}

.form-stack label,
.field {
  display: grid;
  gap: 6px;
}

.form-stack label > span,
.field > span {
  color: #385046;
  font-size: 13px;
  font-weight: 750;
}

.field-note {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.slot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  gap: 8px;
}

.slot-chip {
  min-height: 58px;
  display: grid;
  gap: 2px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  padding: 9px;
  line-height: 1.2;
}

.slot-chip small {
  color: var(--muted);
}

.slot-chip.active {
  border-color: var(--forest);
  background: var(--surface-tint);
}

.slot-chip:disabled {
  cursor: not-allowed;
  background: #eef0ec;
  color: #8a938d;
}

.event-hero {
  display: grid;
  gap: 5px;
  border-color: rgba(31, 111, 91, 0.18);
  background: #fbfcfa;
  padding-block: 14px;
}

.event-hero h2,
.event-hero p {
  margin-bottom: 0;
}

.event-hero .muted {
  overflow-wrap: anywhere;
}

.event-map-link {
  color: var(--forest);
  font-weight: 850;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.promotion-panel {
  display: grid;
  gap: 10px;
  padding-block: 14px;
}

.promotion-panel h2 {
  margin: 0;
  font-size: 18px;
}

.promotion-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 8px;
}

.promotion-chip {
  min-width: 0;
  display: grid;
  gap: 2px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfa;
  padding: 10px;
}

.promotion-chip strong,
.promotion-chip span {
  overflow-wrap: anywhere;
}

.promotion-chip span {
  color: var(--muted);
  font-size: 13px;
}

.eyebrow {
  margin-bottom: 5px;
  color: var(--brand-dark);
  font-weight: 850;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 238px), 1fr));
  gap: 12px;
}

.product-card,
.mini-card,
.metric-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.product-card {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 12px;
  padding: 14px;
}

.product-main {
  min-width: 0;
  display: flex;
  gap: 11px;
  align-items: flex-start;
}

.product-main > div:last-child {
  min-width: 0;
}

.product-main h3,
.product-main p {
  overflow-wrap: anywhere;
}

.product-main p {
  display: -webkit-box;
  max-height: 4.5em;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.product-main strong {
  color: var(--brand-dark);
}

.product-icon {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #f4efe2;
  font-size: 19px;
  line-height: 1;
}

.product-photo {
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f4f7f5;
  object-fit: cover;
}

.product-photo[data-lightbox-image],
.product-image-admin img[data-lightbox-image] {
  cursor: zoom-in;
}

.product-photo[data-lightbox-image]:focus-visible,
.product-image-admin img[data-lightbox-image]:focus-visible {
  outline: 3px solid rgba(31, 111, 91, 0.26);
  outline-offset: 3px;
}

.tag-row,
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag-row span,
.chip-row span,
.status-pill {
  max-width: 100%;
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 3px 8px;
  background: #eef3f0;
  color: #30483f;
  font-size: 12px;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.option-box {
  min-width: 0;
  display: grid;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px;
}

.option-box legend {
  color: var(--forest);
  font-size: 13px;
  font-weight: 800;
}

.option-box label {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
}

.option-box input,
.check-list input {
  width: auto;
}

.product-action-row {
  align-self: end;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.product-action-row small {
  color: var(--muted);
  font-weight: 750;
  overflow-wrap: anywhere;
}

.add-cart-btn {
  min-height: 40px;
}

.cart-box {
  display: grid;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfa;
  padding: 12px;
}

.cart-head,
.cart-item {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.cart-head {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.cart-head h2 {
  margin-bottom: 0;
}

.cart-head small {
  color: var(--muted);
  font-weight: 800;
}

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

.cart-item {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}

.cart-item:first-child {
  border-top: 0;
  padding-top: 0;
}

.cart-item-main {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.cart-item-main strong,
.cart-item-main small {
  overflow-wrap: anywhere;
}

.cart-item-main small {
  color: var(--muted);
}

.cart-stepper {
  grid-column: 1 / 2;
  width: min(100%, 154px);
  grid-template-columns: 34px minmax(0, 1fr) 34px;
}

.cart-stepper button,
.cart-stepper input {
  height: 34px;
}

.cart-item .link-btn {
  justify-self: end;
}

.cart-review-dialog {
  width: min(560px, calc(100% - 28px));
  max-height: min(82vh, 760px);
  border: 0;
  border-radius: var(--radius);
  background: transparent;
  color: var(--ink);
  padding: 0;
}

.cart-review-dialog::backdrop {
  background: rgba(16, 24, 21, 0.58);
  backdrop-filter: blur(4px);
}

.cart-review-panel {
  display: grid;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
  padding: 16px;
}

.cart-review-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.cart-review-head h2,
.cart-review-head p {
  margin-bottom: 0;
}

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

.cart-review-meta span {
  max-width: 100%;
  border-radius: 999px;
  background: #eef3f0;
  color: #30483f;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.cart-review-list {
  display: grid;
  gap: 0;
  max-height: min(42vh, 360px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

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

.cart-review-item:last-child {
  border-bottom: 0;
}

.cart-review-item div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.cart-review-item strong,
.cart-review-item small {
  overflow-wrap: anywhere;
}

.cart-review-item small {
  color: var(--muted);
}

.cart-review-total {
  display: grid;
  gap: 7px;
}

.cart-review-total span {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-weight: 800;
}

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

.cart-review-grand-total {
  border-top: 1px solid var(--line);
  padding-top: 9px;
  color: var(--ink) !important;
  font-size: 18px;
}

.cart-review-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.stepper {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 38px;
  gap: 7px;
}

.stepper button {
  height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--forest);
  font-weight: 900;
}

.stepper input {
  height: 38px;
  text-align: center;
}

.checkout-bar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 40;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(27, 38, 34, 0.96);
  color: #fff;
  padding: 12px max(14px, calc((100vw - 1180px) / 2)) calc(12px + env(safe-area-inset-bottom, 0px));
}

.checkout-bar div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.checkout-bar small {
  color: #d9e7df;
  overflow-wrap: anywhere;
}

.checkout-bar strong {
  font-size: 24px;
}

.btn,
.primary-btn,
.icon-link,
.icon-btn,
.link-btn {
  border-radius: var(--radius);
  font-weight: 850;
}

.btn,
.primary-btn,
.icon-link {
  border: 0;
  background: var(--brand);
  color: #fff;
  padding: 10px 14px;
  text-decoration: none;
}

.primary-btn {
  min-width: 132px;
  min-height: 46px;
}

.btn.ghost,
.icon-link {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--forest);
}

.btn.danger {
  border: 1px solid rgba(189, 45, 45, 0.22);
  background: #fff;
  color: var(--danger);
}

.icon-btn {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--forest);
  padding: 0;
  font-size: 24px;
  line-height: 1;
}

.btn:disabled,
.primary-btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.link-btn {
  border: 0;
  background: transparent;
  color: var(--forest);
  padding: 0;
  text-align: left;
  text-decoration: underline;
}

.notice {
  margin: 0;
  border-radius: var(--radius);
  background: var(--surface-tint);
  color: #17483d;
  padding: 10px 12px;
}

.notice.danger {
  background: #fff0ed;
  color: var(--danger);
}

.admin-toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 30;
  max-width: min(360px, calc(100vw - 36px));
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.hidden,
[hidden] {
  display: none !important;
}

.admin-body {
  min-height: 100vh;
  background: #f6f8f5;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.admin-body .topbar-inner {
  width: min(1440px, calc(100% - 48px));
  min-height: 64px;
}

.admin-body .brand img {
  width: 42px;
  height: 42px;
  flex-basis: 42px;
}

.admin-body .brand strong {
  font-size: 17px;
}

.admin-body .brand small {
  font-size: 12px;
}

.admin-body .btn,
.admin-body .icon-link {
  padding: 8px 12px;
}

.admin-container {
  width: min(1440px, calc(100% - 48px));
  padding-top: 28px;
}

.login-panel {
  width: min(420px, 100%);
  margin: 66px auto;
}

.admin-shell {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.admin-rail,
.admin-main,
.work-grid > *,
.admin-shell > * {
  min-width: 0;
}

.admin-rail {
  position: sticky;
  top: 88px;
  display: grid;
  gap: 16px;
  max-height: calc(100vh - 108px);
  overflow: auto;
  padding-right: 2px;
}

.nav-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 10px;
}

.nav-label {
  margin: 0 0 6px;
  padding: 0 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.admin-tabs {
  display: grid;
  gap: 6px;
}

.admin-tabs a {
  min-height: 40px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: #40534c;
  padding: 9px 11px;
  text-align: left;
  text-decoration: none;
  font-weight: 800;
}

.nav-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  color: currentColor;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-icon path,
.nav-icon circle {
  vector-effect: non-scaling-stroke;
}

.admin-tabs a span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.admin-tabs a.active {
  border-color: rgba(31, 111, 91, 0.28);
  background: var(--surface-tint);
  color: var(--forest);
  box-shadow: 0 1px 0 rgba(20, 37, 31, 0.04);
}

.admin-menu-toggle {
  display: none;
  gap: 8px;
}

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

.admin-main .page-head {
  min-height: 56px;
  margin-bottom: 18px;
  align-items: flex-start;
}

.admin-main .page-head h1 {
  font-size: 28px;
}

.filter-bar {
  justify-content: flex-end;
}

.filter-bar input {
  width: 168px;
}

.section-head {
  min-height: 40px;
  margin-bottom: 12px;
}

.section-head input {
  width: 168px;
}

.venue-list-head {
  align-items: center;
}

.list-filters {
  min-width: 0;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-left: auto;
}

.search-field {
  min-width: min(100%, 280px);
  margin-left: auto;
}

.list-filters .search-field {
  min-width: min(100%, 260px);
  margin-left: 0;
}

.search-field input,
.search-field select {
  width: 100%;
}

.calendar-controls {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.calendar-month-title {
  min-width: 132px;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
}

.calendar-month-picker {
  width: 150px;
}

.view {
  display: none;
}

.view.is-visible {
  display: block;
}

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

.work-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 14px;
  align-items: start;
}

.settings-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.72fr);
  gap: 16px;
  align-items: start;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.8fr);
  gap: 16px;
  align-items: start;
}

.calendar-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 16px;
  align-items: start;
}

.calendar-layout > .panel:first-child {
  overflow: auto;
}

.calendar-side {
  min-width: 0;
  display: grid;
  gap: 14px;
  align-items: start;
}

.event-create-panel {
  border-color: rgba(31, 111, 91, 0.28);
  background: #fbfdfc;
}

.calendar-board {
  min-width: 760px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
}

.calendar-weekday {
  min-height: 38px;
  display: grid;
  place-items: center;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #f0f4f2;
  color: #385046;
  font-size: 12px;
  font-weight: 850;
}

.calendar-weekday:nth-child(7n) {
  border-right: 0;
}

.calendar-day {
  min-height: 126px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fff;
  padding: 8px;
  cursor: pointer;
  transition: background-color 160ms ease, box-shadow 160ms ease;
}

.calendar-day:hover {
  background: #fbfdfc;
  box-shadow: inset 0 0 0 1px rgba(31, 111, 91, 0.18);
}

.calendar-day:nth-child(7n) {
  border-right: 0;
}

.calendar-day:nth-last-child(-n + 7) {
  border-bottom: 0;
}

.calendar-day.is-outside {
  background: #f7f9f6;
  color: #8a958f;
  cursor: default;
}

.calendar-day.is-outside:hover {
  box-shadow: none;
}

.calendar-day.is-today {
  box-shadow: inset 0 0 0 2px rgba(31, 111, 91, 0.3);
}

.calendar-date {
  min-height: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 7px;
}

.calendar-date span {
  font-weight: 850;
}

.calendar-date strong {
  border-radius: 999px;
  background: var(--surface-tint);
  color: var(--forest);
  padding: 2px 7px;
  font-size: 11px;
}

.calendar-events {
  display: grid;
  gap: 6px;
}

.calendar-event {
  position: relative;
  width: 100%;
  display: grid;
  gap: 2px;
  border: 1px solid rgba(31, 111, 91, 0.2);
  border-radius: var(--radius);
  background: #f6fbf9;
  color: var(--ink);
  padding: 7px;
  text-align: left;
}

.calendar-event span,
.calendar-event small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calendar-event span {
  font-size: 12px;
  font-weight: 850;
}

.calendar-event small {
  color: var(--muted);
  font-size: 11px;
}

.calendar-event.is-active {
  border-color: var(--brand);
  background: #fff6f3;
  color: var(--brand-dark);
}

.calendar-editor-body {
  display: grid;
  gap: 12px;
}

.work-grid.two {
  grid-template-columns: minmax(280px, 420px) minmax(0, 1fr);
}

.option-management-grid,
.promotion-management-grid,
.product-management-grid,
.template-management-grid,
.category-management-grid,
.venue-management-grid {
  grid-template-columns: minmax(0, 1fr);
}

.option-list-panel,
.option-create-panel,
.promotion-list-panel,
.promotion-create-panel,
.payment-list-panel,
.payment-create-panel,
.product-list-panel,
.product-create-panel,
.template-list-panel,
.template-create-panel,
.category-list-panel,
.category-create-panel,
.venue-list-panel,
.venue-create-panel {
  grid-column: 1 / -1;
}

.option-create-panel,
.promotion-create-panel,
.payment-create-panel,
.product-create-panel,
.template-create-panel,
.category-create-panel,
.venue-create-panel {
  background: #fbfdfc;
}

.option-create-panel summary,
.promotion-create-panel summary,
.payment-create-panel summary,
.product-create-panel summary,
.template-create-panel summary,
.category-create-panel summary,
.venue-create-panel summary {
  min-height: 38px;
  display: flex;
  align-items: center;
  color: var(--ink);
  cursor: pointer;
  font-size: 18px;
  font-weight: 850;
  list-style: none;
}

.option-create-panel summary::-webkit-details-marker,
.promotion-create-panel summary::-webkit-details-marker,
.payment-create-panel summary::-webkit-details-marker,
.product-create-panel summary::-webkit-details-marker,
.template-create-panel summary::-webkit-details-marker,
.category-create-panel summary::-webkit-details-marker,
.venue-create-panel summary::-webkit-details-marker {
  display: none;
}

.option-create-panel summary::after,
.promotion-create-panel summary::after,
.payment-create-panel summary::after,
.product-create-panel summary::after,
.template-create-panel summary::after,
.category-create-panel summary::after,
.venue-create-panel summary::after {
  content: "+";
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  margin-left: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--forest);
  font-size: 18px;
  line-height: 1;
}

.option-create-panel[open] summary,
.promotion-create-panel[open] summary,
.payment-create-panel[open] summary,
.product-create-panel[open] summary,
.template-create-panel[open] summary,
.category-create-panel[open] summary,
.venue-create-panel[open] summary {
  margin-bottom: 14px;
}

.option-create-panel[open] summary::after,
.promotion-create-panel[open] summary::after,
.payment-create-panel[open] summary::after,
.product-create-panel[open] summary::after,
.template-create-panel[open] summary::after,
.category-create-panel[open] summary::after,
.venue-create-panel[open] summary::after {
  content: "−";
}

.product-card-list,
.venue-card-list,
.category-card-list,
.option-card-list,
.template-card-list {
  display: grid;
  gap: 12px;
}

.option-create-form,
.promotion-create-form,
.product-create-form,
.template-create-form,
.category-create-form,
.venue-create-form {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.option-create-form > *,
.promotion-create-form > *,
.product-create-form > *,
.template-create-form > *,
.category-create-form > *,
.venue-create-form > * {
  min-width: 0;
}

.category-create-name {
  grid-column: span 6;
}

.option-create-name,
.option-create-type,
.template-create-name {
  grid-column: span 4;
}

.option-create-values,
.template-create-description,
.template-create-products {
  grid-column: span 8;
}

.option-create-actions,
.option-create-message,
.promotion-create-name,
.promotion-create-categories,
.promotion-create-products,
.promotion-create-actions,
.promotion-create-message,
.template-create-actions,
.template-create-message,
.category-create-actions,
.category-create-message {
  grid-column: 1 / -1;
}

.option-create-actions,
.promotion-create-actions,
.template-create-actions,
.category-create-actions {
  display: flex;
  align-items: center;
}

.option-create-actions .btn,
.promotion-create-actions .btn,
.template-create-actions .btn,
.category-create-actions .btn {
  min-width: 180px;
}

.promotion-create-condition,
.promotion-create-method,
.promotion-create-amount,
.promotion-create-max,
.promotion-create-threshold,
.promotion-create-quantity,
.promotion-create-enabled {
  grid-column: span 6;
}

.product-create-icon,
.product-create-type {
  grid-column: span 3;
}

.product-create-category,
.product-create-name {
  grid-column: span 6;
}

.product-create-price,
.product-create-limit {
  grid-column: span 3;
}

.product-create-image {
  grid-column: span 6;
}

.product-create-description {
  grid-column: span 6;
}

.product-create-options {
  grid-column: span 6;
}

.product-create-actions,
.product-create-message {
  grid-column: 1 / -1;
}

.product-create-actions {
  display: flex;
  align-items: center;
}

.product-create-actions .btn {
  min-width: 180px;
}

.venue-create-form > .field:nth-child(1),
.venue-create-form > .field:nth-child(2),
.venue-create-type {
  grid-column: span 4;
}

.venue-create-address,
.venue-create-map {
  grid-column: span 6;
}

.venue-create-pickup {
  grid-column: span 5;
}

.venue-create-time {
  grid-column: span 5;
}

.venue-create-capacity {
  grid-column: span 2;
}

.venue-create-pickup textarea {
  height: 58px;
  min-height: 58px;
  overflow: auto;
  resize: vertical;
}

.venue-create-note,
.venue-create-actions {
  grid-column: 1 / -1;
}

.venue-create-actions {
  display: flex;
  align-items: center;
}

.venue-create-actions .btn {
  min-width: 180px;
}

.product-admin-card,
.venue-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 16px;
}

.admin-card-summary {
  position: relative;
  min-width: 0;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 44px;
  padding-right: 34px;
  list-style: none;
  cursor: pointer;
}

.admin-card-summary::-webkit-details-marker {
  display: none;
}

.admin-card-summary::after {
  position: absolute;
  top: 50%;
  right: 2px;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f7faf8;
  color: var(--brand-dark);
  content: "+";
  font-weight: 850;
  transform: translateY(-50%);
}

details[open] > .admin-card-summary {
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

details[open] > .admin-card-summary::after {
  content: "−";
}

.admin-card-title {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.admin-card-title h3 {
  margin: 0;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.admin-card-title .muted {
  overflow-wrap: anywhere;
}

.admin-card-meta {
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.admin-card-body {
  display: grid;
  gap: 12px;
}

.admin-card-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.product-card-summary {
  grid-template-columns: 28px 72px minmax(0, 1fr) auto;
}

.payment-card-summary {
  grid-template-columns: minmax(0, 1fr) auto;
}

.payment-card-summary .status-pill {
  justify-self: end;
}

.drag-handle {
  width: 28px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f7faf8;
  color: var(--muted);
  cursor: grab;
  font-size: 15px;
  font-weight: 850;
  line-height: 1;
  user-select: none;
}

.drag-handle:active {
  cursor: grabbing;
}

.is-sort-dragging {
  opacity: 0.58;
}

[data-sort-list] [data-sort-id] {
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.product-card-head,
.venue-card-head {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 12px;
}

.product-card-head {
  grid-template-columns: 72px minmax(220px, 1fr) auto;
}

.product-image-admin {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f4f7f5;
  color: var(--muted);
  overflow: hidden;
  font-size: 24px;
  font-weight: 850;
}

.product-image-admin img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-title-fields,
.venue-title-fields {
  display: grid;
  gap: 7px;
  max-width: 660px;
}

.product-name-fields {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr);
  gap: 8px;
}

.product-icon-input {
  text-align: center;
}

.product-image-actions {
  display: grid;
  grid-template-columns: minmax(190px, 1fr) auto auto;
  gap: 8px;
  align-items: start;
}

.product-image-uploader {
  position: relative;
  min-width: 0;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 82px;
  border: 1px dashed #b9c9c0;
  border-radius: var(--radius);
  background: #fbfdfc;
  padding: 8px;
  transition: border-color 0.16s ease, background 0.16s ease;
}

.product-image-uploader:hover,
.product-image-uploader.is-dragging {
  border-color: var(--forest);
  background: var(--surface-tint);
}

.product-image-preview {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f4f7f5;
  color: var(--muted);
  overflow: hidden;
  font-size: 12px;
  font-weight: 850;
}

.product-image-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  justify-items: center;
  background: rgba(16, 24, 21, 0.86);
  padding: calc(18px + env(safe-area-inset-top, 0px)) 18px calc(18px + env(safe-area-inset-bottom, 0px));
}

.image-lightbox[hidden] {
  display: none;
}

.image-lightbox-close {
  justify-self: end;
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--ink);
  padding: 8px 14px;
  font-weight: 850;
}

.image-lightbox-image {
  max-width: min(100%, 1080px);
  max-height: 78vh;
  border-radius: var(--radius);
  background: #fff;
  object-fit: contain;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
}

.image-lightbox-caption {
  max-width: min(100%, 720px);
  margin: 0;
  color: #fff;
  text-align: center;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.product-image-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.product-image-copy strong {
  color: #30483f;
  font-size: 13px;
}

.product-image-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.product-card-actions,
.venue-card-actions {
  display: flex;
  gap: 8px;
  align-items: start;
  justify-content: flex-end;
}

.product-card-actions select,
.venue-card-actions select {
  width: min(100%, 180px);
}

.product-card-grid,
.venue-card-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.product-card-grid > *,
.venue-card-grid > * {
  min-width: 0;
}

.product-category-field {
  grid-column: span 4;
}

.product-type-field,
.product-price-field,
.product-limit-field {
  grid-column: span 2;
}

.product-description-field {
  grid-column: span 12;
}

.product-options-field {
  grid-column: span 12;
}

.product-description-field textarea {
  height: 58px;
  min-height: 58px;
  overflow: auto;
  resize: vertical;
}

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

.removable-tag {
  gap: 6px;
}

.removable-tag button {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: rgba(31, 111, 91, 0.13);
  color: var(--brand-dark);
  cursor: pointer;
  font-size: 14px;
  font-weight: 850;
  line-height: 1;
  padding: 0;
}

.removable-tag button:hover {
  background: rgba(201, 72, 50, 0.16);
  color: var(--brand);
}

.inline-add-row {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto;
  gap: 8px;
}

.venue-type-field {
  grid-column: span 2;
}

.venue-address-field,
.venue-pickup-field {
  grid-column: span 6;
}

.venue-map-field,
.venue-time-field {
  grid-column: span 4;
}

.venue-capacity-field {
  grid-column: span 2;
}

.venue-pickup-field {
  align-self: stretch;
}

.venue-pickup-field textarea {
  height: 58px;
  min-height: 58px;
  overflow: auto;
  resize: vertical;
}

.time-range-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.metric-card,
.mini-card {
  padding: 14px;
}

.metric-card {
  display: grid;
  gap: 7px;
  min-height: 92px;
}

.metric-card span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.metric-card strong {
  color: #172d25;
  font-size: 24px;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.table-wrap {
  overflow: auto;
}

.admin-main .table-wrap {
  max-width: 100%;
}

.admin-main .panel {
  padding: 18px;
}

.admin-main table {
  min-width: 680px;
}

.admin-main th,
.admin-main td {
  padding: 11px 12px;
}

.event-summary-wrap {
  min-width: 0;
  overflow: visible;
}

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

.event-summary-row {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(104px, 0.8fr) minmax(148px, 1.25fr) minmax(128px, 1fr) minmax(100px, 0.8fr) minmax(62px, auto);
  gap: 12px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 11px;
}

.event-summary-row.is-selected {
  border-color: rgba(31, 111, 91, 0.38);
  background: var(--surface-tint);
}

.event-summary-row > div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.event-summary-row > div:last-child {
  justify-items: start;
}

.event-summary-row strong,
.event-summary-row span,
.event-summary-row button {
  overflow-wrap: anywhere;
  font-size: 14px;
  line-height: 1.35;
}

.event-summary-label {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
}

.event-summary-date {
  font-size: 14px;
  font-weight: 850;
}

.availability-list-wrap {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.availability-hint {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  margin: 0;
}

.availability-compact-list {
  min-width: 0;
  display: grid;
  gap: 6px;
  max-height: min(62vh, 680px);
  overflow: auto;
  padding-right: 2px;
}

.availability-compact-row {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 9px;
}

.availability-item-title {
  min-width: 0;
  display: grid;
  gap: 2px;
  align-self: center;
}

.availability-item-title strong {
  font-size: 14px;
}

.availability-item-title strong,
.availability-item-title span {
  overflow-wrap: anywhere;
}

.availability-primary-fields {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(118px, 1.2fr) repeat(2, minmax(66px, 0.65fr));
  gap: 8px;
  align-items: end;
}

.compact-field {
  display: grid;
  gap: 3px;
}

.compact-field > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.compact-field input,
.compact-field select {
  min-height: 38px;
  padding: 7px 9px;
}

.availability-save-btn {
  min-height: 38px;
  padding: 7px 12px;
  align-self: center;
}

.availability-extra {
  grid-column: 1 / -1;
}

.availability-extra summary {
  color: var(--forest);
  cursor: pointer;
  font-size: 12px;
  font-weight: 850;
}

.availability-extra-fields {
  display: grid;
  grid-template-columns: minmax(90px, 0.45fr) minmax(0, 1fr);
  gap: 8px;
  margin-top: 8px;
}

.availability-note-field {
  min-width: 0;
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.inline-fields {
  display: grid;
  grid-template-columns: minmax(48px, 72px) minmax(180px, 1fr);
  gap: 8px;
  margin-bottom: 8px;
}

.inline-fields.compact-time {
  grid-template-columns: repeat(2, minmax(100px, 1fr));
}

.check-list {
  display: grid;
  gap: 7px;
  max-height: 180px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 10px;
}

.check-list label {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
}

.discount-category-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.discount-category-checks label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  padding: 7px 10px;
  font-size: 13px;
  font-weight: 750;
}

.discount-category-checks input {
  width: auto;
}

.discount-category-picker {
  display: grid;
  gap: 8px;
}

.discount-category-picker .inline-add-row {
  grid-template-columns: minmax(160px, 1fr) auto;
}

.discount-category-picker .chip-row {
  min-height: 32px;
  align-items: center;
}

.toggle-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #385046;
  font-size: 13px;
  font-weight: 800;
}

.toggle-row input {
  width: auto;
}

.toggle-row.compact {
  flex: 0 0 auto;
}

.toggle-button {
  width: fit-content;
  max-width: 100%;
  display: inline-flex;
  cursor: pointer;
  user-select: none;
}

.toggle-button input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.toggle-button-ui {
  position: relative;
  min-width: 116px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #eef1ee;
  color: var(--muted);
  padding: 5px 14px 5px 42px;
  font-size: 13px;
  font-weight: 850;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.toggle-button-knob {
  position: absolute;
  top: 50%;
  left: 5px;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(104, 115, 109, 0.18);
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(28, 48, 41, 0.14);
  transform: translateY(-50%);
  transition: left 0.18s ease, right 0.18s ease, transform 0.18s ease;
}

.toggle-button-text {
  min-width: 2.5em;
  text-align: center;
}

.toggle-button-text::after {
  content: attr(data-off);
}

.toggle-button input:checked + .toggle-button-ui {
  border-color: rgba(31, 111, 91, 0.3);
  background: var(--surface-tint);
  color: var(--forest);
  padding-right: 42px;
  padding-left: 14px;
}

.toggle-button input:checked + .toggle-button-ui .toggle-button-knob {
  left: calc(100% - 33px);
}

.toggle-button input:checked + .toggle-button-ui .toggle-button-text::after {
  content: attr(data-on);
}

.toggle-button input:focus-visible + .toggle-button-ui {
  box-shadow: 0 0 0 3px rgba(31, 111, 91, 0.16);
}

@media (prefers-reduced-motion: reduce) {
  .toggle-button-ui,
  .toggle-button-knob {
    transition: none;
  }
}

@media (max-width: 960px) {
  .page-grid,
  .admin-shell,
  .work-grid,
  .work-grid.two,
  .settings-grid,
  .dashboard-grid,
  .calendar-layout {
    grid-template-columns: 1fr;
  }

  .page-grid {
    gap: 14px;
    padding-top: 14px;
  }

  .page-grid > .order-flow {
    display: contents;
  }

  .event-selection-panel {
    order: 1;
  }

  .menu-flow {
    order: 2;
  }

  .reservation-panel {
    order: 3;
  }

  .product-management-grid > *,
  .option-management-grid > *,
  .promotion-management-grid > *,
  .template-management-grid > *,
  .category-management-grid > * {
    grid-column: auto;
    grid-row: auto;
  }

  .product-card-head,
  .product-card-actions,
  .product-image-actions,
  .product-card-grid,
  .product-name-fields,
  .venue-card-head,
  .venue-card-actions,
  .venue-card-grid,
  .inline-add-row {
    grid-template-columns: 1fr;
  }

  .admin-card-summary {
    grid-template-columns: 28px minmax(0, 1fr);
    align-items: start;
  }

  .product-card-summary {
    grid-template-columns: 28px 72px minmax(0, 1fr);
  }

  .admin-card-meta,
  .product-card-summary .admin-card-meta {
    grid-column: 2 / -1;
    justify-content: flex-start;
  }

  .category-create-name,
  .option-create-name,
  .option-create-type,
  .option-create-values,
  .option-create-actions,
  .option-create-message,
  .promotion-create-name,
  .promotion-create-condition,
  .promotion-create-method,
  .promotion-create-amount,
  .promotion-create-max,
  .promotion-create-threshold,
  .promotion-create-quantity,
  .promotion-create-enabled,
  .promotion-create-categories,
  .promotion-create-products,
  .promotion-create-actions,
  .promotion-create-message,
  .template-create-name,
  .template-create-description,
  .template-create-products,
  .template-create-actions,
  .template-create-message,
  .category-create-actions,
  .category-create-message,
  .product-category-field,
  .product-type-field,
  .product-price-field,
  .product-limit-field,
  .product-options-field,
  .product-description-field,
  .product-create-icon,
  .product-create-type,
  .product-create-category,
  .product-create-name,
  .product-create-price,
  .product-create-limit,
  .product-create-image,
  .product-create-description,
  .product-create-options,
  .product-create-actions,
  .product-create-message,
  .venue-type-field,
  .venue-address-field,
  .venue-map-field,
  .venue-time-field,
  .venue-capacity-field,
  .venue-pickup-field,
  .venue-create-form > .field:nth-child(1),
  .venue-create-form > .field:nth-child(2),
  .venue-create-type,
  .venue-create-address,
  .venue-create-map,
  .venue-create-pickup,
  .venue-create-time,
  .venue-create-capacity,
  .venue-create-note,
  .venue-create-actions {
    grid-column: auto;
  }

  .option-create-form,
  .promotion-create-form,
  .product-create-form,
  .template-create-form,
  .category-create-form,
  .venue-create-form {
    grid-template-columns: 1fr;
  }

  .admin-rail {
    position: sticky;
    top: 0;
    z-index: 24;
    max-height: none;
    overflow: hidden;
    border-bottom: 1px solid rgba(220, 228, 221, 0.86);
    background: rgba(246, 248, 245, 0.96);
    backdrop-filter: blur(14px);
    padding: 8px 0;
  }

  .admin-menu-toggle {
    display: inline-flex;
    align-items: center;
  }

  .nav-panel {
    display: none;
    padding: 8px;
  }

  .admin-rail.is-menu-open .nav-panel {
    display: block;
  }

  .nav-label {
    margin-bottom: 5px;
  }

  .admin-tabs {
    display: grid;
    gap: 6px;
  }

  .admin-tabs a {
    min-height: 44px;
    white-space: normal;
  }

  .payment-card-summary {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
  }

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

@media (max-width: 560px) {
  .container,
  .page-grid,
  .topbar-inner {
    width: min(100% - 20px, 1180px);
  }

  .admin-container,
  .admin-body .topbar-inner {
    width: min(100% - 20px, 1440px);
  }

  .topbar-inner,
  .page-head,
  .panel-title,
  .section-head {
    align-items: flex-start;
  }

  .event-selection-panel .panel-title {
    grid-template-columns: max-content minmax(144px, 1fr);
    align-items: center;
    gap: 10px;
  }

  .event-selection-panel .panel-title h1 {
    font-size: 22px;
  }

  .event-selection-panel .panel-title input {
    width: 100%;
  }

  .topbar-inner,
  .page-head {
    flex-wrap: wrap;
  }

  .topbar-inner {
    min-height: auto;
    padding: 10px 0;
  }

  .admin-body .topbar {
    background: rgba(255, 255, 255, 0.96);
  }

  .admin-body .topbar-inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 9px;
    padding: 9px 0 10px;
  }

  .admin-body .brand {
    width: 100%;
    gap: 9px;
  }

  .admin-body .brand img {
    width: 38px;
    height: 38px;
    flex-basis: 38px;
  }

  .admin-body .brand strong {
    font-size: 16px;
  }

  .admin-body .brand small {
    font-size: 11px;
  }

  .admin-body .toolbar {
    width: 100%;
    display: grid;
    grid-template-columns: minmax(104px, 1.2fr) repeat(3, minmax(0, auto));
    gap: 8px;
    align-items: center;
  }

  .admin-body .locale-field {
    width: 100%;
    display: block;
  }

  .admin-body .locale-field span {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }

  .admin-body .locale-field select,
  .admin-body .btn,
  .admin-body .icon-link {
    min-height: 40px;
    border-radius: 999px;
    padding-top: 7px;
    padding-bottom: 7px;
  }

  .admin-body .locale-field select {
    width: 100%;
    padding-left: 12px;
  }

  .admin-body .btn,
  .admin-body .icon-link {
    justify-content: center;
    white-space: nowrap;
  }

  .toolbar {
    width: 100%;
    justify-content: space-between;
  }

  input,
  select,
  textarea,
  .btn,
  .primary-btn,
  .icon-link,
  .icon-btn {
    min-height: 44px;
  }

  .icon-btn {
    width: 44px;
    height: 44px;
  }

  .filter-bar {
    width: 100%;
    justify-content: stretch;
  }

  .list-filters {
    width: 100%;
    flex-wrap: wrap;
    justify-content: stretch;
    margin-left: 0;
  }

  .list-filters .search-field {
    flex: 1 1 220px;
  }

  .filter-bar input,
  .filter-bar button,
  .page-head > .toolbar input,
  .page-head > .toolbar button,
  .list-filters .search-field,
  .section-head input {
    width: 100%;
  }

  .page-head > .toolbar {
    width: 100%;
  }

  .page-head > .toolbar input,
  .page-head > .toolbar button,
  .page-head > .toolbar select {
    flex: 1 1 148px;
  }

  .calendar-controls {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .calendar-month-title {
    order: -1;
    width: 100%;
    min-width: 0;
    text-align: left;
    font-size: 21px;
  }

  .calendar-month-picker {
    width: min(100%, 180px);
  }

  .calendar-layout > .panel:first-child {
    overflow: visible;
  }

  .calendar-board {
    min-width: 0;
  }

  .calendar-weekday {
    min-height: 30px;
    font-size: 11px;
  }

  .calendar-day {
    min-height: 74px;
    padding: 5px;
  }

  .calendar-date {
    justify-content: center;
    min-height: 20px;
    margin-bottom: 5px;
  }

  .calendar-date strong {
    display: none;
  }

  .calendar-events {
    place-items: center;
    gap: 4px;
  }

  .calendar-event {
    width: 10px;
    height: 10px;
    min-height: 10px;
    border-radius: 999px;
    background: var(--forest);
    padding: 0;
  }

  .calendar-event.is-active {
    width: 14px;
    height: 14px;
    background: var(--brand);
  }

  .calendar-event span,
  .calendar-event small {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
  }

  .brand img {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
  }

  .brand strong {
    font-size: 16px;
  }

  .split,
  .metric-grid {
    grid-template-columns: 1fr;
  }

  .panel {
    padding: 13px;
  }

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

  .product-card {
    padding: 13px;
  }

  .product-main {
    gap: 10px;
  }

  .product-photo {
    width: 58px;
    height: 58px;
    flex-basis: 58px;
  }

  .option-box label,
  .check-list label {
    min-height: 36px;
  }

  .slot-grid {
    display: flex;
    gap: 8px;
    margin: 0 -13px;
    padding: 0 13px 4px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
  }

  .slot-chip {
    flex: 0 0 94px;
    scroll-snap-align: start;
  }

  .checkout-bar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(126px, 40%);
    padding: 10px;
    padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  }

  .checkout-bar strong {
    font-size: 21px;
  }

  .product-action-row,
  .cart-item {
    grid-template-columns: 1fr;
  }

  .cart-stepper,
  .stepper {
    width: 100%;
    grid-template-columns: 44px minmax(0, 1fr) 44px;
  }

  .cart-stepper button,
  .cart-stepper input,
  .stepper button,
  .stepper input {
    height: 44px;
  }

  .add-cart-btn,
  .cart-item .link-btn {
    width: 100%;
  }

  .cart-item .link-btn {
    justify-self: stretch;
    text-align: center;
  }

  .cart-review-dialog {
    width: min(100% - 20px, 560px);
    max-height: calc(100vh - 24px);
  }

  .cart-review-panel {
    padding: 13px;
  }

  .cart-review-list {
    max-height: 38vh;
  }

  .cart-review-item {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .cart-review-actions .btn {
    flex: 1 1 150px;
  }

  .primary-btn {
    min-width: 0;
    padding: 9px 10px;
  }

  .admin-container {
    padding-top: 12px;
  }

  .admin-body .topbar {
    position: static;
  }

  .admin-rail {
    top: 0;
  }

  .admin-shell {
    gap: 12px;
  }

  .admin-main {
    gap: 14px;
  }

  .admin-main .page-head {
    min-height: 0;
    margin-bottom: 12px;
  }

  .admin-main .page-head h1 {
    font-size: 24px;
  }

  .event-summary-row {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .availability-primary-fields {
    grid-template-columns: minmax(110px, 1fr) repeat(2, minmax(58px, 0.6fr));
  }

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

  .admin-card-summary {
    gap: 9px;
    padding-right: 30px;
  }

  .product-card-summary {
    grid-template-columns: 28px 56px minmax(0, 1fr);
  }

  .product-card-summary .product-image-admin {
    width: 56px;
    height: 56px;
  }

  .payment-card-summary {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .admin-card-meta,
  .product-card-summary .admin-card-meta {
    grid-column: 1 / -1;
  }

  .admin-card-footer,
  .product-card-actions,
  .venue-card-actions,
  .row-actions,
  .option-create-actions,
  .template-create-actions,
  .category-create-actions,
  .product-create-actions,
  .venue-create-actions {
    justify-content: stretch;
  }

  .admin-card-footer .btn,
  .product-card-actions .btn,
  .venue-card-actions .btn,
  .row-actions .btn,
  .option-create-actions .btn,
  .template-create-actions .btn,
  .category-create-actions .btn,
  .product-create-actions .btn,
  .venue-create-actions .btn {
    flex: 1 1 140px;
  }

  .product-card-actions select,
  .venue-card-actions select {
    width: 100%;
  }

  .inline-fields,
  .inline-fields.compact-time,
  .time-range-fields {
    grid-template-columns: 1fr;
  }

  .table-wrap {
    margin-right: -13px;
    margin-left: -13px;
    padding-right: 13px;
    padding-left: 13px;
  }
}

@media (max-width: 420px) {
  .admin-body .toolbar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-body .locale-field {
    grid-column: span 2;
  }

  .admin-body .toolbar > .hidden {
    display: none !important;
  }
}
