@font-face {
  font-family: "Birthstone";
  src: url("/font/Birthstone-Regular.ttf") format("truetype");
  font-display: swap;
  font-weight: 400;
}

@font-face {
  font-family: "Raleway";
  src: url("/font/Raleway-VariableFont_wght.ttf") format("truetype");
  font-display: swap;
  font-weight: 400 900;
}

@font-face {
  font-family: "Raleway";
  src: url("/font/Raleway-Black.ttf") format("truetype");
  font-display: swap;
  font-weight: 900;
}

:root {
  color-scheme: light;
  --bg: #f9f8f4;
  --surface: #fffefa;
  --surface-soft: #f2f0eb;
  --surface-clay: #dccfc2;
  --ink: #2d3a31;
  --muted: #6f756b;
  --faint: #959c91;
  --line: #e6e2da;
  --line-strong: #d8d1c6;
  --sage: #8c9a84;
  --sage-dark: #66745f;
  --terracotta: #c27b66;
  --forest: #26352c;
  --danger: #a65a4b;
  --shadow-sm: 0 1px 4px rgba(45, 58, 49, 0.055);
  --shadow-md: 0 8px 18px rgba(45, 58, 49, 0.065);
  --radius-lg: 7px;
  --radius-md: 5px;
  --radius-sm: 3px;
  --control-h: 28px;
  --font-ui: "Raleway", "Segoe UI", Arial, sans-serif;
  --font-display: "Birthstone", Georgia, serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100vh;
}

body {
  position: relative;
  overflow: hidden;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 12.5px;
  line-height: 1.32;
}

body::before {
  content: "";
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 100;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
}

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

button {
  border: 0;
  cursor: pointer;
}

button:disabled {
  cursor: default;
  opacity: 0.42;
}

.app {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 304px minmax(540px, 1fr) 286px;
  gap: 6px;
  height: 100vh;
  padding: 6px;
  overflow: hidden;
}

.panel {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 254, 250, 0.97);
  box-shadow: var(--shadow-sm);
}

.catalog-panel,
.work-panel,
.settings-panel {
  height: calc(100vh - 12px);
}

.catalog-panel {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
}

.work-panel {
  display: grid;
  grid-template-rows: auto auto auto auto;
  align-content: start;
  overflow: auto;
}

.settings-panel {
  display: grid;
  align-content: start;
  gap: 8px;
  overflow: auto;
  padding: 10px;
}

.panel-head,
.work-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  background: rgba(249, 248, 244, 0.58);
}

h1,
h2,
p {
  margin: 0;
}

h1,
h2 {
  color: var(--forest);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0;
}

h1 {
  font-size: 18px;
  line-height: 1;
}

h2 {
  font-size: 16px;
  line-height: 1.05;
}

.panel-head p,
.work-head p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 400;
}

.toolbar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 8px;
  border-bottom: 1px solid var(--line);
}

#search {
  grid-column: 1 / -1;
}

input,
select,
textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  outline: 0;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

input,
select {
  min-height: var(--control-h);
  padding: 0 8px;
}

textarea {
  min-height: 56px;
  resize: vertical;
  border-radius: var(--radius-sm);
  padding: 6px 8px;
  line-height: 1.25;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--sage);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(140, 154, 132, 0.16);
}

.catalog {
  display: grid;
  grid-auto-rows: max-content;
  gap: 5px;
  overflow: auto;
  padding: 8px;
}

.drink-card {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr) 28px;
  gap: 6px;
  align-items: center;
  min-height: 58px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.74);
}

.drink-card:hover {
  border-color: var(--line-strong);
  background: #fff;
}

.drink-card img,
.selected-item > img {
  width: 50px;
  height: 50px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  background: var(--surface-soft);
}

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

.drink-title {
  color: var(--forest);
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.12;
  overflow-wrap: anywhere;
}

.drink-meta,
.drink-recipe {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 400;
  line-height: 1.18;
}

.drink-recipe {
  max-height: 2.35em;
  overflow: hidden;
}

.drink-actions {
  display: grid;
}

.icon-btn,
.mini-btn,
.secondary,
.primary,
.chat-add button,
.pdf-link {
  min-height: var(--control-h);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, color 180ms ease;
}

.icon-btn,
.mini-btn,
.secondary {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  color: var(--forest);
}

.icon-btn,
.mini-btn {
  display: inline-grid;
  place-items: center;
  width: var(--control-h);
  min-width: var(--control-h);
  padding: 0;
}

.icon-btn.is-active {
  border-color: rgba(140, 154, 132, 0.55);
  background: rgba(140, 154, 132, 0.14);
  color: var(--sage-dark);
}

.icon-control svg,
button svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.secondary {
  padding: 0 11px;
}

.primary,
.chat-add button,
.pdf-link {
  width: 100%;
  background: var(--forest);
  color: #fff;
}

.primary:hover,
.chat-add button:hover,
.pdf-link:hover {
  background: var(--terracotta);
}

.secondary:hover,
.icon-btn:hover,
.mini-btn:hover {
  border-color: var(--sage);
  color: var(--sage-dark);
  transform: translateY(-1px);
}

.work-head .secondary {
  width: var(--control-h);
  min-width: var(--control-h);
  padding: 0;
  font-size: 0;
}

.auth-bar {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(130px, 1fr) minmax(110px, 0.8fr) 74px 82px 74px;
  gap: 6px;
  align-items: center;
  padding: 7px 8px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 254, 250, 0.82);
}

.auth-status {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-status[data-state="signed-in"] {
  color: var(--sage-dark);
}

.auth-bar .secondary {
  width: 100%;
  padding: 0 6px;
  font-size: 10.5px;
}

.live-preview-wrap {
  display: grid;
  gap: 5px;
  padding: 8px;
  border-bottom: 1px solid var(--line);
}

.project-bar {
  display: grid;
  grid-template-columns: minmax(120px, 1.1fr) minmax(120px, 1fr) minmax(120px, 1fr) minmax(120px, 1fr) 48px 70px;
  gap: 6px;
  align-items: end;
  padding: 8px;
  border-bottom: 1px solid var(--line);
  background: rgba(242, 240, 235, 0.48);
}

.project-bar label {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 600;
  line-height: 1.1;
}

.project-bar .secondary {
  width: 100%;
  padding: 0 8px;
}

.save-state {
  display: grid;
  place-items: center;
  min-height: var(--control-h);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.save-state[data-state="saved"] {
  border-color: rgba(140, 154, 132, 0.45);
  color: var(--sage-dark);
}

.save-state[data-state="saving"] {
  color: var(--terracotta);
}

.save-state[data-state="error"] {
  color: var(--danger);
}

.live-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.live-preview-head h2 {
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.page-controls {
  display: flex;
  align-items: center;
  gap: 4px;
}

.page-controls span {
  min-width: 34px;
  color: var(--muted);
  font-size: 11px;
  text-align: center;
}

.page-controls .mini-btn {
  width: 26px;
  min-width: 26px;
  min-height: 26px;
}

.menu-preview {
  position: relative;
  display: grid;
  grid-template-rows: 20% minmax(0, 1fr) 7%;
  overflow: hidden;
  width: min(100%, 860px);
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
  aspect-ratio: 260 / 140;
}

.menu-preview.empty {
  display: grid;
  place-items: center;
  min-height: 104px;
  color: var(--muted);
  font-size: 12px;
}

.preview-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2.2%;
  min-height: 0;
  background-position: center;
  background-size: cover;
  color: #fff;
}

.preview-fresh {
  font-family: var(--font-display);
  font-size: clamp(19px, 4.2vw, 42px);
  font-style: normal;
  font-weight: 400;
  line-height: 1;
}

.preview-menu {
  font-family: var(--font-ui);
  font-size: clamp(22px, 4.6vw, 44px);
  font-weight: 900;
  letter-spacing: 0.03em;
}

.preview-grid {
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  grid-template-rows: repeat(var(--rows), minmax(0, 1fr));
  min-height: 0;
  padding: 0.8% 3.2% 0;
}

.preview-drink {
  position: relative;
  display: grid;
  grid-template-rows: var(--image-row, 68%) var(--title-row, 11%) var(--subtitle-row, 6%) minmax(0, var(--recipe-row, 15%));
  justify-items: center;
  min-width: 0;
  min-height: 0;
  padding: 0 1.8%;
  text-align: center;
}

.preview-choice {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

.preview-choice::after {
  content: "";
  pointer-events: none;
  position: absolute;
  inset: 2%;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.preview-choice:hover::after,
.preview-choice:focus-visible::after {
  border-color: rgba(140, 154, 132, 0.55);
  background: rgba(140, 154, 132, 0.06);
}

.preview-choice.is-preview-selected::after {
  border-color: rgba(194, 123, 102, 0.75);
  background: rgba(194, 123, 102, 0.08);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.72);
}

.preview-drink img {
  grid-row: 1;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
  transform: scale(var(--drink-image-zoom, 1));
  transform-origin: center bottom;
}

.preview-drink .price-circle {
  right: 13%;
  bottom: calc(var(--recipe-row, 15%) + var(--subtitle-row, 6%) + var(--title-row, 11%) + 4%);
}

.preview-title {
  grid-row: 2;
  max-width: 100%;
  align-self: start;
  color: var(--forest);
  font-size: clamp(7.8px, 1.08vw, 13.6px);
  font-weight: 900;
  line-height: 1.03;
  overflow-wrap: anywhere;
}

.preview-subtitle {
  grid-row: 3;
  max-width: 100%;
  align-self: start;
  color: #984449;
  font-size: clamp(6.4px, 0.86vw, 9.4px);
  font-weight: 700;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.preview-recipe {
  grid-row: 4;
  max-width: 100%;
  align-self: start;
  color: var(--ink);
  font-size: clamp(5.7px, 0.74vw, 8.2px);
  font-weight: 500;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.preview-title + .preview-recipe {
  grid-row: 3 / 5;
}

.preview-footer {
  display: grid;
  place-items: center;
  min-height: 0;
  color: var(--muted);
  font-size: clamp(5px, 0.72vw, 7.8px);
}

.arch-preview {
  grid-template-columns: 31% minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr) 7%;
  background: #fff;
}

.arch-backdrop {
  position: relative;
  z-index: 0;
  grid-column: 1;
  grid-row: 1 / -1;
  min-height: 0;
  background-position: center;
  background-size: cover;
}

.arch-photo {
  position: relative;
  z-index: 1;
  grid-column: 1;
  grid-row: 1 / -1;
  min-height: 0;
  overflow: hidden;
  background-position: center;
  background-size: cover;
  border-radius: 48% 48% 0 0 / 28% 28% 0 0;
  clip-path: inset(0 round 48% 48% 0 0 / 28% 28% 0 0);
  -webkit-mask-position: center;
  mask-position: center;
  transform: translate(var(--arch-offset-x, 0), var(--arch-offset-y, 0));
}

.arch-preview.arc-low .arch-photo {
  height: 84%;
  border-radius: 42% 42% 0 0 / 19% 19% 0 0;
  clip-path: inset(0 round 42% 42% 0 0 / 19% 19% 0 0);
}

.arch-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(38, 53, 44, 0.22);
}

.arch-title {
  position: absolute;
  z-index: 2;
  left: 4.1%;
  top: 15%;
  display: grid;
  color: #fff;
  line-height: 0.88;
  pointer-events: none;
}

.arch-title span {
  font-family: var(--font-display);
  font-size: clamp(22px, 4.8vw, 50px);
  font-style: normal;
  font-weight: 400;
}

.arch-title strong {
  margin-left: 34%;
  font-family: var(--font-ui);
  font-size: clamp(22px, 4vw, 42px);
  font-weight: 900;
}

.arch-grid {
  display: grid;
  grid-column: 2;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  align-items: stretch;
  min-height: 0;
  height: 100%;
  padding: 1.2% 1.8% 0 1.4%;
}

.arch-drink {
  position: relative;
  display: grid;
  grid-template-rows: var(--arch-image-row, 66%) 12% 6% minmax(0, 1fr);
  min-width: 0;
  min-height: 0;
  padding: 0 1.5%;
  text-align: center;
}

.arch-image-wrap {
  position: relative;
  grid-row: 1;
  min-height: 0;
  display: grid;
  place-items: end center;
}

.arch-image-wrap img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
  transform: scale(var(--drink-image-zoom, 1));
  transform-origin: center bottom;
}

.price-circle {
  position: absolute;
  right: 7%;
  bottom: 7%;
  display: grid;
  place-items: center;
  width: calc(clamp(18px, 3vw, 30px) * var(--price-circle-scale, 1.25));
  aspect-ratio: 1;
  border: 1px solid rgba(160, 130, 110, 0.24);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--terracotta);
  font-size: calc(clamp(5.6px, 0.78vw, 9px) * var(--price-circle-scale, 1.25));
  font-weight: 900;
  line-height: 1;
}

.arch-footer {
  grid-column: 2;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: clamp(4.8px, 0.68vw, 7.2px);
  text-align: center;
}

.selected {
  display: grid;
  align-content: start;
  gap: 5px;
  min-height: 0;
  max-height: min(48vh, 520px);
  overflow: auto;
  padding: 8px;
}

.selected.empty {
  align-content: start;
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 62px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-md);
  color: var(--muted);
  padding: 14px;
  text-align: center;
}

.selected-item {
  display: grid;
  grid-template-columns: 18px 50px minmax(0, 1fr) 60px;
  gap: 6px;
  align-items: start;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.78);
}

.selected-item.is-active {
  border-color: rgba(194, 123, 102, 0.6);
  background: rgba(194, 123, 102, 0.07);
  box-shadow: inset 3px 0 0 rgba(194, 123, 102, 0.75);
}

.selected-index {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border-radius: var(--radius-sm);
  background: var(--surface-soft);
  color: var(--sage-dark);
  font-size: 10px;
  font-weight: 700;
}

.selected-editor {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) 104px 64px;
  gap: 4px;
  min-width: 0;
}

.selected-editor label,
.chat-add label,
.settings-panel label {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 600;
  line-height: 1.1;
}

.selected-editor .wide {
  grid-column: 1 / -1;
}

.product-variants {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 6px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(242, 240, 235, 0.46);
}

.product-slot select[multiple] {
  min-height: 78px;
  padding: 4px 6px;
}

.selected-editor textarea {
  min-height: 36px;
  max-height: 58px;
}

.selected-editor input,
.selected-editor select,
.selected-editor textarea {
  min-height: 25px;
  font-size: 11px;
  line-height: 1.15;
}

.selected-actions {
  display: grid;
  grid-template-columns: repeat(2, 26px);
  gap: 4px;
  justify-content: end;
}

.selected-actions .mini-btn {
  width: 26px;
  min-width: 26px;
  min-height: 25px;
}

.chat-add {
  display: grid;
  gap: 6px;
  padding: 8px;
  border-top: 1px solid var(--line);
}

.chat-add textarea {
  min-height: 48px;
}

.arc-options {
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface-soft);
}

.arc-options label:nth-child(2) {
  grid-column: auto;
}

.is-arch-layout .arc-options {
  display: grid;
}

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

.arc-options .position-grid {
  grid-column: 1 / -1;
}

.background-preview {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background-position: center;
  background-size: cover;
}

.range-field {
  gap: 5px;
}

.range-field span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.range-field output {
  color: var(--forest);
  font-size: 10px;
  font-weight: 700;
}

input[type="range"] {
  min-height: 18px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  accent-color: var(--forest);
}

.spec {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

.spec div {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 8px;
  padding: 5px 8px;
  border-bottom: 1px solid var(--line);
  font-size: 10px;
}

.spec div:last-child {
  border-bottom: 0;
}

.spec strong {
  color: var(--forest);
  font-weight: 700;
}

.spec span {
  color: var(--muted);
}

.shopping-panel,
.email-panel {
  display: grid;
  gap: 6px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.65);
}

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

.shopping-head h2 {
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.shopping-head .mini-btn {
  width: auto;
  min-width: 74px;
  padding: 0 10px;
}

.secondary.wide {
  width: 100%;
}

.email-config {
  max-width: 145px;
  color: var(--sage-dark);
  font-size: 9.5px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.email-config.is-error,
.email-status.error {
  color: var(--danger);
}

.email-status {
  min-height: 16px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.2;
}

.shopping-list {
  display: grid;
  gap: 2px;
  max-height: 118px;
  overflow: auto;
  color: var(--muted);
  font-size: 10.5px;
}

.shopping-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 6px;
  padding: 4px 0;
  border-top: 1px solid var(--line);
}

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

.shopping-item strong {
  color: var(--forest);
  font-size: 10.5px;
  font-weight: 700;
}

.shopping-item a {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.shopping-item span {
  color: var(--sage-dark);
  font-size: 10px;
  font-weight: 600;
  text-align: right;
}

.shopping-item small {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.18;
}

.status {
  min-height: 18px;
  color: var(--muted);
  font-size: 11px;
}

.status.error {
  color: var(--danger);
}

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

.hidden {
  display: none;
}

.pdf-link {
  display: grid;
  place-items: center;
  min-height: 34px;
  text-decoration: none;
}

.package-path {
  padding: 7px 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

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

.previews img {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #fff;
}

@media (max-width: 1200px) {
  .app {
    grid-template-columns: 280px minmax(460px, 1fr);
  }

  .settings-panel {
    grid-column: 1 / -1;
    height: auto;
    max-height: 44vh;
  }
}

@media (max-width: 860px) {
  body {
    overflow: auto;
  }

  .app {
    display: grid;
    grid-template-columns: 1fr;
    height: auto;
    min-height: 100vh;
  }

  .catalog-panel,
  .work-panel,
  .settings-panel {
    height: auto;
    max-height: none;
  }

  .catalog-panel {
    max-height: 58vh;
  }

  .toolbar,
  .project-bar,
  .selected-editor,
  .arc-options {
    grid-template-columns: 1fr;
  }

  .selected-item {
    grid-template-columns: 18px 42px minmax(0, 1fr);
  }

  .selected-actions {
    grid-column: 1 / -1;
    display: flex;
    justify-content: stretch;
  }

  .selected-actions .mini-btn,
  .icon-btn,
  .mini-btn {
    flex: 1;
  }
}
