* {
  box-sizing: border-box;
}
body {
  margin: 0;
  font:
    13px "DM Sans",
    Arial,
    sans-serif;
  color: #292327;
  background: #f6f4f2;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a {
  cursor: pointer;
}
button {
  color: inherit;
  background: none;
  border: 0;
}
a {
  color: inherit;
  text-decoration: none;
}
[hidden] {
  display: none !important;
}
.brand {
  font:
    600 43px "Playfair Display",
    Georgia,
    serif;
  letter-spacing: -2px;
}
.gate {
  max-width: 500px;
  margin: 14vh auto;
  text-align: center;
  padding: 35px;
}
.gate h1 {
  font-size: 28px;
}
.gate p {
  line-height: 1.8;
  color: #766e72;
}
.gate a {
  display: block;
  margin-top: 22px;
}
.primary {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  background: #6b1f39;
  color: white;
  padding: 13px 21px;
  font-size: 12px;
  border: 0;
  gap: 14px;
}
.quiet {
  font-size: 12px;
  color: #786b72;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 225px;
  padding: 35px 25px;
  background: #fff;
  border-right: 1px solid #e7e0e4;
  display: flex;
  flex-direction: column;
}
.side-caption {
  font-size: 8px;
  letter-spacing: 2px;
  margin: 15px 0 38px;
  color: #93868d;
}
.sidebar nav {
  display: grid;
  gap: 7px;
}
.sidebar nav button {
  text-align: left;
  padding: 14px;
  font-size: 12px;
}
.sidebar nav button.selected {
  background: #f4e9ed;
  color: #6b1f39;
  font-weight: 600;
}
.side-bottom {
  margin-top: auto;
  display: grid;
  gap: 17px;
  font-size: 11px;
}
.side-bottom span {
  color: #96878e;
  word-break: break-all;
  font-size: 10px;
}
.workspace {
  margin-left: 225px;
  padding: 0 40px 60px;
}
.admin-top {
  height: 79px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #e5dfe2;
  margin-bottom: 35px;
  font-size: 9px;
  letter-spacing: 1.4px;
}
.admin-top button {
  font-size: 11px;
  letter-spacing: 0;
}
.page-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 25px;
}
h1 {
  font-size: 31px;
  font-weight: 500;
  letter-spacing: -1px;
  margin: 0 0 8px;
}
h2 {
  font-size: 24px;
  font-weight: 500;
  margin-top: 0;
}
h3 {
  font-size: 15px;
  font-weight: 500;
}
p {
  line-height: 1.8;
}
.muted {
  font-size: 11px;
  color: #81737b;
}
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin: 24px 0;
}
.stat {
  background: #fff;
  padding: 22px;
  border: 1px solid #e7e0e4;
}
.stat strong {
  display: block;
  font-size: 29px;
  font-weight: 500;
  margin-bottom: 7px;
}
.stat span {
  font-size: 11px;
  color: #81737b;
}
.toolbar {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  margin: 25px 0 18px;
}
.toolbar input {
  flex: 1;
  max-width: 440px;
}
.toolbar input,
.toolbar select {
  padding: 12px;
  border: 1px solid #ded5d9;
  background: #fff;
}
.table-wrap {
  overflow: auto;
  background: #fff;
  border: 1px solid #e5dee1;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}
th {
  font-size: 9px;
  letter-spacing: 0.7px;
  font-weight: 500;
  color: #897982;
  background: #fcfafb;
  padding: 15px;
}
td {
  padding: 16px 15px;
  border-top: 1px solid #eee8eb;
  font-size: 11px;
}
td button {
  color: #6b1f39;
  text-decoration: underline;
  font-size: 11px;
}
.product-cell {
  display: flex;
  gap: 13px;
  align-items: center;
  min-width: 200px;
}
.product-cell img {
  width: 45px;
  height: 58px;
  object-fit: cover;
  background: #f3efeb;
}
.product-cell small {
  display: block;
  margin-top: 5px;
  color: #8c7e85;
}
.badge {
  display: inline-block;
  padding: 5px 8px;
  border-radius: 3px;
  background: #eee8e2;
  color: #79634d;
  font-size: 9px;
}
.badge.on {
  background: #e6f2e8;
  color: #386b42;
}
.badge.pending {
  background: #fceccf;
  color: #856524;
}
.badge.off {
  background: #f0e9ed;
  color: #8a6273;
}
.empty {
  padding: 65px 25px;
  text-align: center;
  color: #8b7d85;
  line-height: 1.9;
}
.panel {
  padding: 28px;
  background: #fff;
  border: 1px solid #e6dfe2;
  margin-bottom: 22px;
}
.panel p {
  font-size: 12px;
  color: #7b6f75;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.wide {
  grid-column: 1/-1;
}
label {
  display: block;
  font-size: 11px;
  margin-bottom: 17px;
}
label input:not([type="checkbox"]),
label textarea,
label select {
  display: block;
  width: 100%;
  padding: 12px;
  border: 1px solid #dcd2d7;
  margin-top: 8px;
  background: #fff;
  color: #292327;
}
input[type="checkbox"] {
  accent-color: #6b1f39;
}
.check {
  display: flex;
  align-items: center;
  gap: 9px;
  line-height: 1.7;
}
.help {
  color: #8c7c85;
  font-size: 10px;
  line-height: 1.8;
  margin-top: 8px;
}
.section-label {
  font-size: 11px;
  letter-spacing: 1px;
  border-top: 1px solid #e6dfe2;
  padding-top: 24px;
  margin-top: 25px;
}
dialog {
  border: 0;
  background: white;
  width: min(840px, 95vw);
  padding: 38px;
  max-height: 92dvh;
  color: #292327;
}
dialog::backdrop {
  background: #25192070;
  backdrop-filter: blur(3px);
}
.close {
  position: absolute;
  right: 15px;
  top: 12px;
  font-size: 27px;
}
.variant-row {
  display: grid;
  grid-template-columns: 1fr 1fr 32px;
  gap: 12px;
  align-items: center;
}
.variant-row input {
  width: 100%;
  border: 1px solid #ded3d9;
  padding: 10px;
}
.variant-row button {
  font-size: 23px;
  color: #925d71;
}
.variant-head {
  display: grid;
  grid-template-columns: 1fr 1fr 32px;
  gap: 12px;
  font-size: 10px;
  color: #8b7b83;
  margin: 12px 0;
}
.variant-row {
  margin-bottom: 9px;
}
.outline {
  border: 1px solid #a9949f;
  padding: 10px 15px;
  font-size: 11px;
}
.image-list {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin: 15px 0;
}
.image-tile {
  position: relative;
}
.image-tile img {
  width: 90px;
  height: 110px;
  object-fit: cover;
}
.image-tile button {
  position: absolute;
  right: 2px;
  top: 2px;
  background: white;
  width: 23px;
  height: 23px;
}
.actions {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-top: 25px;
}
.actions .danger {
  margin-left: auto;
  color: #a12e4f;
}
.notice {
  padding: 15px 18px;
  background: #fcf0dd;
  color: #88632e;
  font-size: 11px;
  line-height: 1.8;
  margin: 15px 0;
}
.detail-list {
  display: grid;
  grid-template-columns: 130px 1fr;
  font-size: 12px;
  gap: 12px;
  margin: 25px 0;
}
.detail-list dt {
  color: #8d7c86;
}
.detail-list dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.order-lines {
  font-size: 11px;
  padding: 15px;
  background: #f7f4f5;
  line-height: 1.9;
  white-space: pre-wrap;
}
.tiny {
  font-size: 9px;
  color: #90818a;
}
.error {
  color: #a22447;
}
.saving {
  opacity: 0.6;
  pointer-events: none;
}
#status {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  background: #442739;
  color: #fff;
  padding: 14px 22px;
  z-index: 100;
  max-width: 90vw;
  display: none;
  font-size: 12px;
}
#status.show {
  display: block;
}
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 2px solid #883454;
  outline-offset: 3px;
}
@media (max-width: 850px) {
  .sidebar {
    width: 185px;
    padding: 25px 15px;
  }
  .workspace {
    margin-left: 185px;
    padding: 0 22px 40px;
  }
  .sidebar .brand {
    font-size: 37px;
  }
  .stats {
    gap: 10px;
  }
  .stat {
    padding: 16px;
  }
}
@media (max-width: 600px) {
  .sidebar {
    position: static;
    width: 100%;
    padding: 20px;
    border-bottom: 1px solid #e2d7dd;
  }
  .side-caption,
  .side-bottom {
    display: none;
  }
  .sidebar nav {
    display: flex;
    overflow-x: auto;
    margin-top: 18px;
    gap: 3px;
  }
  .sidebar nav button {
    white-space: nowrap;
    padding: 11px;
    font-size: 10px;
  }
  .workspace {
    margin: 0;
    padding: 0 17px 40px;
  }
  .admin-top {
    height: 58px;
    margin-bottom: 25px;
  }
  .page-title {
    align-items: start;
  }
  .page-title h1 {
    font-size: 25px;
  }
  .page-title .primary {
    padding: 12px;
    font-size: 10px;
  }
  .stats {
    gap: 8px;
  }
  .stat {
    padding: 13px;
  }
  .stat strong {
    font-size: 24px;
  }
  .stat span {
    font-size: 9px;
  }
  .toolbar {
    flex-direction: column;
  }
  .toolbar input {
    max-width: none;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .panel {
    padding: 20px;
  }
  .detail-list {
    grid-template-columns: 85px 1fr;
    font-size: 11px;
    gap: 10px;
  }
  dialog {
    padding: 35px 20px;
    max-height: 94dvh;
  }
  .actions {
    flex-wrap: wrap;
  }
  .variant-row {
    grid-template-columns: 1fr 75px 26px;
  }
  .variant-head {
    grid-template-columns: 1fr 75px 26px;
  }
  .brand {
    font-size: 37px;
  }
}
