:root {
  color-scheme: light;
  --bg: #f2f4f6;
  --panel: #ffffff;
  --text: #191f28;
  --muted: #8b95a1;
  --muted-strong: #6b7684;
  --line: #e5e8eb;
  --blue: #3182f6;
  --blue-dark: #1b64da;
  --blue-soft: #e8f3ff;
  --chip: #f2f4f6;
  --shadow: 0 1px 2px rgb(0 0 0 / 4%);
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
}

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

.shell {
  width: min(860px, 100%);
  margin: 0 auto;
  padding: 14px 18px 28px;
}

.hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 2px 12px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--blue);
  font-size: 14px;
  font-weight: 800;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.18;
}

.statusText {
  max-width: 520px;
  margin-top: 6px;
  color: var(--muted-strong);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
}

button,
select,
input,
textarea {
  min-height: 44px;
  border: 0;
  border-radius: 12px;
  color: var(--text);
  padding: 0 15px;
}

input,
textarea,
select {
  background: var(--chip);
}

textarea {
  min-height: 180px;
  padding: 13px 15px;
  resize: vertical;
  line-height: 1.5;
}

button {
  cursor: pointer;
  background: var(--blue);
  color: #fff;
  font-weight: 800;
  box-shadow: var(--shadow);
}

button:hover {
  background: var(--blue-dark);
}

button:disabled {
  cursor: wait;
  opacity: 0.62;
}

.secondaryButton {
  background: var(--chip);
  color: var(--text);
}

.secondaryButton:hover {
  background: #e5e8eb;
}

.dangerButton {
  background: #fee;
  color: #d92d20;
}

.dangerButton:hover {
  background: #ffd6d6;
}

.toolbar {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
  padding: 12px;
  border-radius: 20px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.toolbar label {
  display: grid;
  gap: 8px;
  width: min(100%, 280px);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.iconButton {
  width: 44px;
  padding: 0;
  background: var(--chip);
  color: var(--text);
  font-size: 28px;
  line-height: 1;
}

.iconButton:hover {
  background: #e5e8eb;
}

.toolbar select {
  width: 100%;
  background: var(--chip);
  color: var(--text);
  font-weight: 800;
}

.emptyState,
.menuCard {
  border-radius: 24px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.emptyState {
  display: grid;
  min-height: 320px;
  place-items: center;
  color: var(--muted-strong);
  text-align: center;
  padding: 30px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.5;
}

.hidden {
  display: none;
}

.menuCard {
  overflow: hidden;
}

.menuHeader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 6px;
}

.menuHeader span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--blue-soft);
  color: var(--blue);
  font-size: 13px;
  font-weight: 900;
}

.menuHeader strong {
  color: var(--muted-strong);
  font-size: 14px;
  font-weight: 800;
}

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

.cornerCard {
  min-width: 0;
  padding: 14px;
  border-radius: 20px;
  background: #f9fafb;
}

.cornerCard:first-child {
  background: #f7fbff;
}

.cornerCard h2 {
  margin-bottom: 10px;
  font-size: 21px;
  font-weight: 850;
  letter-spacing: -0.02em;
}

.mealImage {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  margin: 0 0 10px;
  object-fit: cover;
  border-radius: 16px;
  background: var(--chip);
}

.cornerCard:first-child h2 {
  color: var(--blue);
}

.cornerCard ol {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cornerCard li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 40px;
  padding: 7px 9px;
  border-radius: 14px;
  background: #fff;
  line-height: 1.35;
}

.cornerCard li span {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: 50%;
  background: var(--chip);
  color: var(--muted-strong);
  font-size: 12px;
  font-weight: 900;
}

.cornerCard:first-child li span {
  background: var(--blue-soft);
  color: var(--blue);
}

.cornerCard li strong {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 15px;
  font-weight: 760;
  letter-spacing: -0.01em;
}

.notice {
  color: var(--muted);
  font-weight: 800;
}

.editorPanel {
  margin-top: 12px;
  padding: 18px;
  border-radius: 24px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.editorPanel header,
.editorActions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.editorPanel h2 {
  font-size: 21px;
  letter-spacing: -0.02em;
}

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

.formGrid label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.formGrid label:nth-child(n + 3) {
  grid-column: span 1;
}

.editorActions {
  justify-content: flex-start;
  margin-top: 14px;
}

.editStatus {
  color: var(--muted-strong);
  font-size: 14px;
  font-weight: 700;
}

@media (max-width: 720px) {
  .shell {
    padding: 8px 10px 16px;
  }

  .hero,
  .toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .hero {
    gap: 8px;
    padding: 8px 2px 8px;
  }

  h1 {
    font-size: 22px;
  }

  .eyebrow {
    margin-bottom: 4px;
    font-size: 12px;
  }

  .statusText {
    margin-top: 4px;
    font-size: 12px;
    line-height: 1.35;
  }

  .toolbar {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) 38px;
    gap: 8px;
    padding: 8px;
    border-radius: 16px;
  }

  .toolbar label {
    gap: 5px;
    font-size: 11px;
  }

  .iconButton {
    width: 38px;
    min-height: 38px;
    font-size: 24px;
  }

  .toolbar label {
    width: 100%;
  }

  .menuHeader {
    flex-direction: row;
    padding: 12px 14px 4px;
  }

  .menuHeader span {
    min-height: 26px;
    padding: 0 9px;
    font-size: 12px;
  }

  .menuHeader strong {
    font-size: 13px;
  }

  .menuGrid {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 8px;
  }

  .cornerCard {
    padding: 10px;
    border-radius: 16px;
  }

  .cornerCard h2 {
    margin-bottom: 7px;
    font-size: 18px;
  }

  .mealImage {
    aspect-ratio: 16 / 9;
    margin-bottom: 7px;
    border-radius: 12px;
  }

  .cornerCard ol {
    gap: 5px;
  }

  .cornerCard li {
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 8px;
    min-height: 34px;
    padding: 5px 8px;
    border-radius: 12px;
  }

  .cornerCard li span {
    width: 22px;
    height: 22px;
    font-size: 11px;
  }

  .cornerCard li strong {
    font-size: 13px;
    line-height: 1.25;
  }

  .editorPanel header,
  .editorActions {
    align-items: stretch;
    flex-direction: column;
  }

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