:root {
  --red: #8e1b14;
  --red-dark: #71130e;
  --red-soft: #fff0ec;
  --orange: #f87820;
  --yellow: #ffc13d;
  --cream: #fff4df;
  --cream-2: #fffaf2;
  --paper: #ffffff;
  --ink: #28100d;
  --muted: #76615b;
  --muted-2: #9b8983;
  --line: rgba(71, 24, 18, .13);
  --line-strong: rgba(71, 24, 18, .22);
  --green: #24845e;
  --green-soft: #eaf8f1;
  --danger: #b3261e;
  --danger-soft: #fff0ee;
  --shadow-sm: 0 12px 30px rgba(68, 24, 17, .08);
  --shadow-lg: 0 32px 80px rgba(68, 24, 17, .15);
  --radius-xl: 30px;
  --radius-lg: 22px;
  --radius-md: 16px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: var(--cream-2);
  font-family: 'DM Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
}

[hidden] {
  display: none !important;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

button,
input[type='checkbox'],
input[type='file'] {
  cursor: pointer;
}

button:disabled,
input:disabled {
  cursor: not-allowed;
}

img {
  display: block;
  max-width: 100%;
}

:focus-visible {
  outline: 3px solid rgba(248, 120, 32, .42);
  outline-offset: 3px;
}

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

.admin-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  width: fit-content;
  font-family: 'Fredoka', sans-serif;
  font-size: 20px;
  white-space: nowrap;
}

.admin-brand img {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 8px 20px rgba(155, 35, 22, .2);
}

.admin-brand strong {
  color: var(--red);
}

.admin-brand small {
  display: inline-flex;
  margin-left: 5px;
  border-radius: 999px;
  padding: 4px 7px;
  background: var(--red-soft);
  color: var(--red);
  font-family: 'DM Sans', sans-serif;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  vertical-align: middle;
}

.eyebrow,
.panel-kicker {
  color: var(--red);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.eyebrow::before {
  width: 22px;
  height: 3px;
  border-radius: 99px;
  background: var(--orange);
  content: '';
}

.button {
  min-height: 44px;
  border: 0;
  border-radius: 13px;
  padding: 11px 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 800;
  line-height: 1;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease, opacity .18s ease;
}

.button:not(:disabled):hover {
  transform: translateY(-1px);
}

.button:disabled {
  opacity: .62;
}

.button-primary {
  background: var(--red);
  color: #fff;
  box-shadow: 0 12px 26px rgba(142, 27, 20, .2);
}

.button-primary:not(:disabled):hover {
  background: var(--red-dark);
  box-shadow: 0 15px 32px rgba(142, 27, 20, .26);
}

.button-ghost {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
}

.button-ghost:not(:disabled):hover {
  background: var(--cream-2);
}

.login-view {
  position: relative;
  min-height: 100vh;
  padding: 40px 20px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 15% 15%, rgba(255, 193, 61, .32), transparent 28%),
    radial-gradient(circle at 88% 82%, rgba(248, 120, 32, .16), transparent 31%),
    linear-gradient(150deg, #fffaf2 0%, #fff1dc 100%);
}

.login-view::before {
  position: absolute;
  inset: 0;
  opacity: .32;
  background-image: radial-gradient(rgba(142, 27, 20, .18) .8px, transparent .8px);
  background-size: 22px 22px;
  content: '';
  pointer-events: none;
}

.login-decoration {
  position: absolute;
  border: 2px dashed rgba(142, 27, 20, .13);
  border-radius: 50%;
  pointer-events: none;
}

.decoration-one {
  top: -160px;
  right: -120px;
  width: 430px;
  height: 430px;
}

.decoration-two {
  bottom: -200px;
  left: -130px;
  width: 520px;
  height: 520px;
}

.login-card {
  position: relative;
  z-index: 1;
  width: min(100%, 500px);
  border: 1px solid rgba(113, 19, 14, .1);
  border-radius: 34px;
  padding: 42px;
  background: rgba(255, 255, 255, .92);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(18px);
}

.login-brand {
  margin-bottom: 44px;
}

.login-copy h1,
.dashboard-intro h1,
.panel-heading h2 {
  font-family: 'Fredoka', sans-serif;
  letter-spacing: -.03em;
}

.login-copy h1 {
  margin: 13px 0 12px;
  font-size: clamp(38px, 8vw, 52px);
  line-height: .98;
}

.login-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.login-form {
  margin-top: 30px;
  display: grid;
  gap: 9px;
}

.login-form > label,
.image-upload-field > label:first-child {
  font-size: 12px;
  font-weight: 800;
}

.image-upload-field > label:first-child span,
.field > span:first-child b {
  color: var(--red);
}

.password-field {
  position: relative;
}

.password-field input,
.field > input,
.field > textarea,
.price-input-wrap,
.search-field {
  border: 1px solid var(--line);
  background: #fff;
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

.password-field input,
.field > input,
.field > textarea {
  width: 100%;
  border-radius: 13px;
  padding: 12px 13px;
  outline: 0;
  color: var(--ink);
}

.password-field input {
  min-height: 51px;
  padding-right: 72px;
}

.password-field input:focus,
.field > input:focus,
.field > textarea:focus,
.price-input-wrap:focus-within,
.search-field:focus-within {
  border-color: rgba(142, 27, 20, .56);
  box-shadow: 0 0 0 4px rgba(142, 27, 20, .08);
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  min-width: 55px;
  border: 0;
  border-radius: 9px;
  padding: 7px 8px;
  transform: translateY(-50%);
  background: var(--cream);
  color: var(--red);
  font-size: 11px;
  font-weight: 800;
}

.login-submit {
  width: 100%;
  min-height: 51px;
  margin-top: 5px;
}

.form-feedback {
  margin: 3px 0;
  border-radius: 11px;
  padding: 10px 11px;
  background: var(--danger-soft);
  color: var(--danger);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
}

.form-feedback[data-tone='success'] {
  background: var(--green-soft);
  color: var(--green);
}

.back-link {
  display: block;
  margin-top: 25px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
}

.back-link:hover,
.storefront-link:hover {
  color: var(--red);
}

.dashboard-view {
  min-height: 100vh;
  background:
    radial-gradient(circle at 95% 3%, rgba(255, 193, 61, .18), transparent 21%),
    var(--cream-2);
}

.admin-header {
  position: sticky;
  z-index: 30;
  top: 0;
  border-bottom: 1px solid rgba(71, 24, 18, .08);
  background: rgba(255, 250, 242, .9);
  backdrop-filter: blur(18px);
}

.admin-header-inner {
  width: min(1400px, calc(100% - 48px));
  min-height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.storefront-link {
  margin-right: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.session-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border-radius: 999px;
  padding: 8px 11px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.session-badge i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 4px rgba(36, 132, 94, .12);
}

.dashboard-main {
  width: min(1400px, calc(100% - 48px));
  margin: 0 auto;
  padding: 52px 0 70px;
}

.dashboard-intro {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
}

.dashboard-intro h1 {
  margin: 11px 0 8px;
  font-size: clamp(38px, 5vw, 60px);
  line-height: .98;
}

.dashboard-intro p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.intro-action {
  flex: 0 0 auto;
  border-radius: 999px;
  padding-inline: 20px;
}

.stats-grid {
  margin: 30px 0 22px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 15px;
}

.stat-card {
  min-height: 112px;
  border: 1px solid rgba(71, 24, 18, .09);
  border-radius: var(--radius-lg);
  padding: 19px;
  display: flex;
  align-items: center;
  gap: 15px;
  background: rgba(255, 255, 255, .82);
  box-shadow: var(--shadow-sm);
}

.stat-icon {
  width: 54px;
  height: 54px;
  flex: 0 0 auto;
  border-radius: 17px;
  display: grid;
  place-items: center;
  font-size: 22px;
  font-style: normal;
  font-weight: 900;
}

.stat-icon-total {
  background: var(--cream);
}

.stat-icon-ready {
  background: var(--green-soft);
  color: var(--green);
}

.stat-icon-empty {
  background: var(--red-soft);
  color: var(--red);
}

.stat-card > div {
  display: grid;
  gap: 2px;
}

.stat-card span:not(.stat-icon) {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.stat-card strong {
  font-family: 'Fredoka', sans-serif;
  font-size: 30px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.62fr) minmax(330px, .78fr);
  gap: 22px;
  align-items: start;
}

.surface {
  border: 1px solid rgba(71, 24, 18, .09);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, .9);
  box-shadow: var(--shadow-sm);
}

.inventory-panel,
.add-menu-panel {
  min-width: 0;
  padding: 25px;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.panel-heading h2 {
  margin: 5px 0 3px;
  font-size: 28px;
}

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

.icon-action {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: var(--cream-2);
  color: var(--red);
  font-size: 21px;
  transition: transform .18s ease, background .18s ease;
}

.icon-action:not(:disabled):hover {
  transform: rotate(12deg);
  background: var(--cream);
}

.icon-action:disabled {
  opacity: .55;
}

.inventory-toolbar {
  margin: 21px 0 13px;
}

.search-field {
  width: 100%;
  min-height: 46px;
  border-radius: 14px;
  padding: 0 13px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--muted-2);
}

.search-field > span:first-child {
  transform: rotate(-15deg);
  font-size: 23px;
  line-height: 1;
}

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

.menu-list {
  min-height: 250px;
  display: grid;
  align-content: start;
  gap: 11px;
}

.list-state {
  min-height: 250px;
  border: 1px dashed var(--line-strong);
  border-radius: 20px;
  padding: 34px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  color: var(--muted);
  text-align: center;
}

.list-state strong {
  color: var(--ink);
  font-family: 'Fredoka', sans-serif;
  font-size: 20px;
}

.list-state p {
  max-width: 380px;
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
}

.list-state.error {
  border-color: rgba(179, 38, 30, .28);
  background: var(--danger-soft);
  color: var(--danger);
}

.spinner {
  width: 27px;
  height: 27px;
  border: 3px solid rgba(142, 27, 20, .16);
  border-top-color: var(--red);
  border-radius: 50%;
  animation: spin .75s linear infinite;
}

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

.menu-admin-card {
  position: relative;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 19px;
  padding: 12px;
  display: grid;
  grid-template-columns: 104px minmax(180px, 1fr) minmax(250px, .84fr);
  gap: 15px;
  align-items: center;
  background: #fff;
  transition: border-color .18s ease, box-shadow .18s ease, opacity .18s ease;
}

.menu-admin-card:hover {
  border-color: rgba(142, 27, 20, .22);
  box-shadow: 0 12px 25px rgba(68, 24, 17, .07);
}

.menu-admin-card.is-sold-out {
  background: #fcfaf8;
}

.menu-thumbnail {
  position: relative;
  width: 104px;
  height: 92px;
  margin: 0;
  border-radius: 15px;
  overflow: hidden;
  background: var(--cream);
}

.menu-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.menu-admin-card.is-sold-out .menu-thumbnail img {
  filter: grayscale(.45);
  opacity: .72;
}

.stock-overlay {
  position: absolute;
  right: 6px;
  bottom: 6px;
  border-radius: 999px;
  padding: 5px 7px;
  background: rgba(40, 16, 13, .86);
  color: #fff;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
  backdrop-filter: blur(5px);
}

.menu-info {
  min-width: 0;
}

.menu-labels {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.category-pill,
.badge-pill {
  max-width: 100%;
  border-radius: 999px;
  padding: 5px 7px;
  overflow: hidden;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: .07em;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.category-pill {
  background: var(--red-soft);
  color: var(--red);
}

.badge-pill {
  background: #fff2c9;
  color: #795400;
}

.menu-info h3 {
  margin: 7px 0 5px;
  overflow: hidden;
  font-family: 'Fredoka', sans-serif;
  font-size: 18px;
  line-height: 1.12;
  text-overflow: ellipsis;
}

.menu-info > p {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.item-edit-form {
  min-width: 0;
  border-left: 1px solid var(--line);
  padding-left: 15px;
  display: grid;
  grid-template-columns: minmax(105px, 1fr) minmax(114px, auto) auto;
  gap: 9px;
  align-items: end;
}

.compact-field {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.compact-field > span,
.stock-control > span:first-child {
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.compact-price {
  min-width: 0;
  height: 39px;
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 0 9px;
  display: flex;
  align-items: center;
  background: var(--cream-2);
}

.compact-price:focus-within {
  border-color: rgba(142, 27, 20, .5);
  box-shadow: 0 0 0 3px rgba(142, 27, 20, .07);
}

.compact-price i {
  color: var(--red);
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}

.compact-price input {
  width: 100%;
  min-width: 0;
  border: 0;
  padding: 0 0 0 5px;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}

.stock-control {
  display: grid;
  gap: 5px;
}

.stock-toggle {
  position: relative;
  min-width: 114px;
  height: 39px;
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 0 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 7px;
  background: var(--cream-2);
}

.stock-toggle input,
.availability-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.stock-toggle strong {
  color: var(--red);
  font-size: 9px;
  font-weight: 900;
}

.stock-toggle input:checked ~ strong {
  color: var(--green);
}

.mini-switch,
.switch {
  position: relative;
  flex: 0 0 auto;
  border-radius: 999px;
  background: #cbbcb6;
  transition: background .18s ease;
}

.mini-switch {
  width: 30px;
  height: 18px;
}

.mini-switch::after,
.switch::after {
  position: absolute;
  top: 3px;
  left: 3px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 6px rgba(40, 16, 13, .22);
  content: '';
  transition: transform .18s ease;
}

.mini-switch::after {
  width: 12px;
  height: 12px;
}

.stock-toggle input:checked ~ .mini-switch,
.availability-option input:checked ~ .switch {
  background: var(--green);
}

.stock-toggle input:checked ~ .mini-switch::after {
  transform: translateX(12px);
}

.stock-toggle:focus-within,
.availability-option:focus-within {
  outline: 3px solid rgba(248, 120, 32, .38);
  outline-offset: 2px;
}

.item-save-button {
  width: 39px;
  height: 39px;
  border: 0;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  transition: transform .18s ease, background .18s ease;
}

.item-save-button:not(:disabled):hover {
  transform: translateY(-1px);
  background: var(--red);
}

.item-save-button:disabled {
  opacity: .58;
}

.item-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

.item-delete-button {
  min-height: 39px;
  border: 1px solid rgba(177, 39, 31, .22);
  border-radius: 11px;
  padding: 0 11px;
  background: #fff1ef;
  color: var(--danger);
  font-size: 11px;
  font-weight: 900;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.item-delete-button:not(:disabled):hover {
  transform: translateY(-1px);
  border-color: var(--danger);
  background: #ffe5e1;
}

.item-delete-button:disabled {
  opacity: .58;
}

.item-feedback {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--danger);
  font-size: 10px;
  font-weight: 700;
  line-height: 1.4;
}

.add-menu-panel {
  position: sticky;
  top: 98px;
  scroll-margin-top: 98px;
}

.add-menu-form {
  margin-top: 21px;
  display: grid;
  gap: 15px;
}

.image-upload-field {
  display: grid;
  gap: 7px;
}

.image-dropzone {
  position: relative;
  aspect-ratio: 2 / 1.04;
  border: 1.5px dashed var(--line-strong);
  border-radius: 17px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: var(--cream-2);
  transition: border-color .18s ease, background .18s ease, transform .18s ease;
}

.image-dropzone:hover,
.image-dropzone.is-dragging {
  border-color: var(--red);
  background: var(--cream);
}

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

.image-dropzone.has-preview::after {
  position: absolute;
  inset: auto 9px 9px auto;
  border-radius: 999px;
  padding: 6px 9px;
  background: rgba(40, 16, 13, .8);
  color: #fff;
  content: 'Ganti foto';
  font-size: 9px;
  font-weight: 800;
  backdrop-filter: blur(7px);
}

.image-placeholder {
  display: grid;
  place-items: center;
  gap: 4px;
  color: var(--muted);
  text-align: center;
}

.image-placeholder b {
  width: 39px;
  height: 39px;
  margin-bottom: 3px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: var(--red-soft);
  color: var(--red);
  font-size: 23px;
  font-weight: 500;
}

.image-placeholder strong {
  color: var(--ink);
  font-size: 12px;
}

.image-placeholder small,
.field-hint {
  color: var(--muted-2);
  font-size: 9px;
}

.field-hint {
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.field {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.field > span:first-child {
  font-size: 11px;
  font-weight: 800;
}

.field > span:first-child small {
  margin-left: 4px;
  color: var(--muted-2);
  font-size: 8px;
  font-weight: 700;
}

.field > input,
.field > textarea,
.price-input-wrap {
  min-height: 43px;
  border-radius: 12px;
  font-size: 12px;
}

.field > textarea {
  min-height: 80px;
  resize: vertical;
  line-height: 1.5;
}

.price-input-wrap {
  padding: 0 12px;
  display: flex;
  align-items: center;
}

.price-input-wrap i {
  color: var(--red);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.price-input-wrap input {
  width: 100%;
  min-width: 0;
  border: 0;
  padding: 10px 0 10px 7px;
  outline: 0;
  background: transparent;
  color: var(--ink);
}

.availability-option {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--cream-2);
}

.availability-option > span {
  display: grid;
  gap: 2px;
}

.availability-option strong {
  font-size: 11px;
}

.availability-option small {
  color: var(--muted);
  font-size: 9px;
}

.switch {
  width: 39px;
  height: 23px;
}

.switch::after {
  width: 17px;
  height: 17px;
}

.availability-option input:checked ~ .switch::after {
  transform: translateX(16px);
}

.form-submit {
  width: 100%;
  min-height: 48px;
}

.toast-stack {
  position: fixed;
  z-index: 100;
  right: 22px;
  bottom: 22px;
  width: min(360px, calc(100% - 32px));
  display: grid;
  gap: 9px;
  pointer-events: none;
}

.toast-message {
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 15px;
  padding: 13px 15px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  transform: translateY(12px);
  opacity: 0;
  background: var(--ink);
  color: #fff;
  box-shadow: 0 18px 40px rgba(40, 16, 13, .25);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
  transition: transform .22s ease, opacity .22s ease;
}

.toast-message::before {
  width: 21px;
  height: 21px;
  flex: 0 0 auto;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--green);
  content: '✓';
  font-size: 11px;
}

.toast-message.error::before {
  background: var(--danger);
  content: '!';
}

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

noscript {
  position: fixed;
  z-index: 200;
  inset: 0 0 auto;
  padding: 12px;
  background: var(--danger);
  color: #fff;
  font-weight: 800;
  text-align: center;
}

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

  .add-menu-panel {
    position: static;
  }

  .add-menu-form {
    grid-template-columns: minmax(270px, .7fr) 1fr;
    align-items: start;
  }

  .image-upload-field {
    grid-row: span 4;
  }

  .image-dropzone {
    aspect-ratio: 1.3 / 1;
  }

  .add-menu-form > .form-feedback,
  .add-menu-form > .form-submit {
    grid-column: 2;
  }
}

@media (max-width: 920px) {
  .menu-admin-card {
    grid-template-columns: 94px minmax(0, 1fr);
  }

  .menu-thumbnail {
    width: 94px;
    height: 86px;
  }

  .item-edit-form {
    grid-column: 1 / -1;
    border-top: 1px solid var(--line);
    border-left: 0;
    padding-top: 11px;
    padding-left: 0;
  }
}

@media (max-width: 760px) {
  .admin-header-inner,
  .dashboard-main {
    width: min(100% - 28px, 1400px);
  }

  .admin-header-inner {
    min-height: 68px;
  }

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

  .admin-brand img {
    width: 40px;
    height: 40px;
    border-radius: 12px;
  }

  .admin-brand small,
  .session-badge,
  .storefront-link {
    display: none;
  }

  .header-actions {
    gap: 8px;
  }

  .header-actions .button {
    min-height: 40px;
    padding: 9px 13px;
    font-size: 12px;
  }

  .dashboard-main {
    padding: 38px 0 55px;
  }

  .dashboard-intro {
    display: grid;
  }

  .dashboard-intro h1 {
    font-size: 43px;
  }

  .intro-action {
    justify-self: start;
  }

  .stats-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 9px;
  }

  .stat-card {
    min-height: 104px;
    padding: 14px;
    display: grid;
    gap: 9px;
  }

  .stat-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    font-size: 16px;
  }

  .stat-card strong {
    font-size: 25px;
  }

  .inventory-panel,
  .add-menu-panel {
    border-radius: 23px;
    padding: 18px;
  }

  .add-menu-form {
    grid-template-columns: 1fr;
  }

  .image-upload-field {
    grid-row: auto;
  }

  .image-dropzone {
    aspect-ratio: 2 / 1.05;
  }

  .add-menu-form > .form-feedback,
  .add-menu-form > .form-submit {
    grid-column: auto;
  }
}

@media (max-width: 540px) {
  .login-view {
    padding: 18px 13px;
  }

  .login-card {
    border-radius: 27px;
    padding: 28px 21px;
  }

  .login-brand {
    margin-bottom: 35px;
  }

  .login-copy h1 {
    font-size: 41px;
  }

  .dashboard-intro p {
    font-size: 13px;
  }

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

  .stat-card {
    min-height: 82px;
    display: flex;
  }

  .stat-card > div {
    width: 100%;
    grid-template-columns: 1fr auto;
    align-items: center;
  }

  .stat-card strong {
    grid-row: span 2;
    grid-column: 2;
  }

  .panel-heading h2 {
    font-size: 25px;
  }

  .menu-admin-card {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 11px;
  }

  .menu-thumbnail {
    width: 76px;
    height: 76px;
  }

  .menu-info h3 {
    font-size: 16px;
  }

  .menu-info > p {
    -webkit-line-clamp: 1;
  }

  .item-edit-form {
    grid-template-columns: 1fr 1fr auto;
  }

  .stock-toggle {
    min-width: 0;
  }

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

  .toast-stack {
    right: 16px;
    bottom: 16px;
  }
}

@media (max-width: 390px) {
  .item-edit-form {
    grid-template-columns: 1fr auto;
  }

  .stock-control {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .item-actions {
    grid-column: 2;
    grid-row: 1;
  }

  .item-delete-button {
    padding-inline: 9px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
