@font-face {
  font-family: Share;
  src: url('/assets/ShareTechMono-Regular.ttf');
}
@font-face {
  font-family: Space;
  src: url('/assets/SpaceGrotesk-Regular.ttf');
}
@font-face {
  font-family: Space;
  src: url('/assets/SpaceGrotesk-Medium.ttf');
  font-weight: 500;
}
[hidden] {
  display: none !important;
}
:root {
  font-family: Space, system-ui, sans-serif;
  color: #292929;
  background: #f3eee6;
  --orange: #dc6d24;
  --muted: #76716b;
  --line: #e2dbd0;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
textarea,
select {
  font: inherit;
}
button {
  cursor: pointer;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 16px;
  background: #fff;
  color: inherit;
  font-weight: 500;
}
button:hover {
  background: #f5e8d9;
}
button:disabled {
  opacity: 0.48;
  cursor: default;
}
button.primary {
  background: #e4772b;
  color: #191919;
  border-color: #e4772b;
}
button.primary:hover {
  background: #ef914b;
}
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 3px solid #e4772b66;
  outline-offset: 2px;
}
h1,
h2,
h3 {
  font-family: Share, monospace;
  font-weight: 400;
  margin: 0;
}
h1 {
  font-size: 34px;
}
h2 {
  font-size: 25px;
}
p {
  line-height: 1.6;
}
label {
  font-size: 13px;
  color: #615d57;
  display: grid;
  gap: 7px;
}
input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 11px;
  padding: 11px 13px;
  color: #292929;
}
textarea {
  resize: vertical;
  min-height: 140px;
}
small,
.muted {
  color: var(--muted);
}
.login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: radial-gradient(ellipse at 20% 20%, #e7a16e20, transparent 65%);
}
.login-card {
  width: min(490px, calc(100% - 36px));
  padding: 40px;
  background: #fffaf5d9;
  border: 1px solid #fff;
  border-radius: 25px;
  box-shadow: 0 18px 70px #4631190a;
}
.brand {
  display: flex;
  align-items: center;
  gap: 15px;
}
.brand img {
  width: 105px;
  height: 40px;
  object-fit: contain;
}
.brand-title {
  border-left: 1px solid #d4c9b9;
  padding-left: 15px;
  font-family: Share;
  font-size: 25px;
}
.brand small {
  font-family: Space;
  font-size: 11px;
  display: block;
  margin-top: 4px;
}
.login-card button {
  width: 100%;
  margin-top: 26px;
  padding: 14px;
}
.login-card p {
  font-size: 14px;
  color: var(--muted);
  margin-top: 23px;
}
.shell {
  display: grid;
  grid-template-columns: 225px 1fr;
  min-height: 100vh;
}
.sidebar {
  background: #262626;
  color: #f6efe6;
  padding: 29px 20px;
  display: flex;
  flex-direction: column;
  gap: 35px;
}
.sidebar .brand {
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}
.sidebar .brand img {
  background: #f4eee5;
  border-radius: 8px;
  padding: 5px;
  width: 123px;
  height: 48px;
}
.sidebar .brand-title {
  border: 0;
  padding: 0;
  font-size: 23px;
}
.sidebar nav {
  display: grid;
  gap: 7px;
}
.sidebar nav button {
  text-align: left;
  border: 0;
  background: transparent;
  color: #c2bcb5;
  padding: 13px 15px;
}
.sidebar nav button.active {
  background: #e8792d;
  color: #1e1e1e;
}
.identity {
  margin-top: auto;
  font-size: 12px;
  overflow-wrap: anywhere;
  color: #aaa39a;
  display: grid;
  gap: 12px;
}
.identity button {
  background: transparent;
  border-color: #555;
  color: #eee;
  width: 100%;
}
main {
  padding: 36px 40px;
  min-width: 0;
}
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 26px;
}
.eyebrow {
  font-family: Share;
  font-size: 12px;
  color: #8b7767;
  letter-spacing: 2px;
  margin-bottom: 9px;
}
.topbar p {
  margin: 7px 0 0;
  font-size: 14px;
  color: var(--muted);
}
.toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}
.toolbar input {
  max-width: 350px;
}
.workspace {
  display: grid;
  grid-template-columns: minmax(220px, 330px) minmax(300px, 1fr);
  gap: 24px;
  align-items: start;
}
.panel {
  background: #fffaf5;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
}
.list {
  max-height: calc(100vh - 265px);
  overflow: auto;
  padding: 7px;
}
.product-row,
.employee-row {
  width: 100%;
  background: transparent;
  border: 0;
  border-radius: 11px;
  text-align: left;
  padding: 16px;
  margin: 2px 0;
  display: grid;
  gap: 6px;
}
.product-row.selected,
.employee-row.selected {
  background: #f2e4d5;
  box-shadow: inset 3px 0 var(--orange);
}
.product-row small {
  font-size: 12px;
}
.editor {
  padding: 28px;
}
.editor-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 15px;
  margin-bottom: 27px;
}
.editor-header h2 {
  max-width: 70%;
  overflow-wrap: anywhere;
}
.save-status {
  white-space: nowrap;
  font-size: 12px;
  color: #757269;
  display: flex;
  align-items: center;
  gap: 7px;
}
.save-status.saving:before {
  content: '';
  width: 10px;
  height: 10px;
  border: 2px solid #e2dbd0;
  border-top-color: var(--orange);
  border-radius: 50%;
  animation: spin 1.8s linear infinite;
}
.save-status.error {
  color: #a33c20;
}
.fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 19px;
}
.full {
  grid-column: 1/-1;
}
.empty {
  padding: 70px 25px;
  text-align: center;
  color: #96918a;
  font-size: 23px;
  line-height: 1.5;
}
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border-top: 1px solid var(--line);
  font-size: 12px;
}
.pagination button {
  padding: 6px 10px;
}
.message {
  margin-top: 20px;
  border-radius: 12px;
  background: #fff0dc;
  padding: 14px;
  font-size: 13px;
  line-height: 1.5;
}
.message button {
  margin: 10px 8px 0 0;
}
.permissions {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin: 20px 0;
}
.permissions th,
.permissions td {
  padding: 10px 7px;
  border-bottom: 1px solid var(--line);
  text-align: center;
}
.permissions th:first-child,
.permissions td:first-child {
  text-align: left;
}
.permissions input {
  width: 17px;
  height: 17px;
  accent-color: var(--orange);
}
#notice:empty {
  display: none;
}
#notice {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: #292929;
  color: #fff;
  padding: 12px 20px;
  border-radius: 14px;
  z-index: 10;
  font-size: 14px;
  max-width: 90vw;
}
.loading {
  padding: 100px;
  text-align: center;
  color: var(--muted);
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
@media (prefers-reduced-motion: reduce) {
  .save-status.saving:before {
    animation: none;
  }
}
@media (max-width: 1000px) {
  main {
    padding: 25px;
  }
  .shell {
    grid-template-columns: 180px 1fr;
  }
  .workspace {
    grid-template-columns: 1fr;
  }
  .list {
    max-height: 260px;
  }
  .sidebar {
    padding: 25px 15px;
  }
}
@media (max-width: 650px) {
  .shell {
    display: block;
  }
  .sidebar {
    padding: 18px;
    gap: 18px;
  }
  .sidebar .brand {
    flex-direction: row;
    align-items: center;
  }
  .sidebar nav {
    display: flex;
  }
  .identity {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .identity button {
    width: auto;
  }
  .workspace {
    gap: 16px;
  }
  .topbar {
    align-items: start;
  }
  .fields {
    grid-template-columns: 1fr;
  }
  .editor {
    padding: 20px;
  }
  main {
    padding: 22px 16px;
  }
  .permissions {
    font-size: 11px;
  }
  .permissions th,
  .permissions td {
    padding: 10px 3px;
  }
  .save-status {
    white-space: normal;
  }
}
