:root {
  color-scheme: light;
  --studio: #fff;
  --panel: #fff;
  --ink: #171717;
  --muted: #777;
  --soft: #a3a3a3;
  --line: #e9e9e7;
  --line-strong: #d8d8d5;
  --accent: #222;
  --accent-soft: #f2f2f1;
  --sans:
    Inter, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial,
    "PingFang SC", "Microsoft YaHei", sans-serif;
}
* {
  box-sizing: border-box;
}
html,
body,
#appShell {
  height: 100%;
  min-height: 100dvh;
}
body {
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
button,
input,
select {
  font: inherit;
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.38;
  cursor: not-allowed;
}
button:focus-visible,
input:focus-visible,
select:focus-visible,
.canvas-stage:focus-visible {
  outline: 2px solid #777;
  outline-offset: 3px;
}
[hidden] {
  display: none !important;
}
.app-shell {
  grid-template-columns: 268px minmax(0, 1fr);
  height: 100dvh;
  overflow: hidden;
  background: #fff;
}
.sidebar {
  flex-direction: column;
  min-width: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-right: 1px solid var(--line);
}
.side-section {
  padding-top: 21px;
  margin-top: 21px;
  border-top: 1px solid var(--line);
}
.side-section.filter-section {
  padding-top: 0;
  margin-top: 0;
  border-top: 0;
}
.composition-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.composition {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  text-align: center;
  padding: 10px 8px;
  border: 1px solid #e6e6e4;
  background: #fff;
  color: #6e6e6e;
  font-size: 10px;
  transition:
    background 0.16s,
    border-color 0.16s,
    color 0.16s;
}
.composition:hover {
  border-color: #aaa;
  color: #222;
}
.composition.active {
  background: #222;
  border-color: #222;
  color: #fff;
  font-weight: 570;
}
.setting-list {
  display: grid;
  gap: 15px;
}
.range-setting {
  display: block;
  min-width: 0;
}
.range-setting > span {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: #666;
  font-size: 10px;
}
.range-setting output {
  color: #777;
  font-variant-numeric: tabular-nums;
  font-size: 9px;
}
.range-setting input[type="range"] {
  display: block;
  width: 100%;
  appearance: none;
  height: 2px;
  border-radius: 99px;
  background: #dededc;
  margin: 11px 0 1px;
  accent-color: #333;
  cursor: pointer;
}
.range-setting input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #222;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px #777;
}
.range-setting input[type="range"]::-moz-range-thumb {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #222;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px #777;
}
.workspace {
  position: relative;
  min-width: 0;
  min-height: 0;
  height: 100dvh;
  overflow: hidden;
  background: #fff;
}
.viewport {
  position: relative;
  height: 100%;
  overflow: hidden;
  isolation: isolate;
}
.viewport::before {
  content: "";
  position: absolute;
}
.viewport::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse at 50% 45%,
    transparent 48%,
    rgba(0, 0, 0, 0.018) 100%
  );
}
.canvas-stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
  touch-action: none;
  cursor: grab;
  outline: 0;
  z-index: 1;
  perspective: 1800px;
  perspective-origin: 50% 50%;
}
.canvas-stage:active {
  cursor: grabbing;
}
.scene {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transform-origin: 50% 50%;
  pointer-events: none;
  will-change: transform;
}
.focus-layer {
  position: absolute;
  inset: 0;
  z-index: 5;
  overflow: visible;
  pointer-events: none;
}
.ticket-card.focus-source-hidden {
  visibility: hidden !important;
}
.ticket-card.focus-card {
  z-index: 10000 !important;
  pointer-events: auto;
  cursor: pointer;
  transform-origin: center center;
  transition:
    transform 0.56s cubic-bezier(0.18, 0.72, 0.18, 1),
    opacity 0.16s ease;
  will-change: transform;
}
.ticket-card.focus-card .card-visual {
  transform: scale(1) !important;
  transition: none;
}
.ticket-card.focus-card .ticket-shadow {
  opacity: 0.32 !important;
  bottom: -10%;
  height: 28%;
}
.ticket-card {
  position: absolute;
  left: 50%;
  top: 50%;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  transform-origin: center;
  transform-style: preserve-3d;
  display: block;
  pointer-events: auto;
  cursor: pointer;
  user-select: none;
  outline: 0;
  backface-visibility: hidden;
  transition:
    opacity 0.28s ease,
    transform 0.62s cubic-bezier(0.18, 0.72, 0.18, 1);
}
.card-visual {
  position: absolute;
  inset: 0;
  display: block;
  transform: scale(1);
  transform-style: preserve-3d;
  transition: transform 0.62s cubic-bezier(0.18, 0.72, 0.18, 1);
}
.ticket-card.selected {
  z-index: 999 !important;
}
.ticket-card.selected .card-visual {
  transform: scale(1.08);
  will-change: transform;
}
.ticket-shadow {
  position: absolute;
  left: 5%;
  right: 5%;
  bottom: -12%;
  height: 30%;
  z-index: 0;
  border-radius: 50%;
  background: radial-gradient(
    ellipse at center,
    rgba(0, 0, 0, 0.115) 0%,
    rgba(0, 0, 0, 0.065) 28%,
    rgba(0, 0, 0, 0.022) 55%,
    rgba(0, 0, 0, 0) 78%
  );
  opacity: 0.3;
  transform: scale(1.08, 1);
  pointer-events: none;
}
.ticket-flip-inner {
  position: absolute;
  inset: 0;
  z-index: 1;
  transform-style: preserve-3d;
  transition: transform 0.62s cubic-bezier(0.2, 0.72, 0.18, 1);
  backface-visibility: hidden;
}
.ticket-card.is-back .ticket-flip-inner {
  transform: rotateY(180deg);
}
.ticket-face {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transform-style: preserve-3d;
}
.ticket-face img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
  user-select: none;
  filter: none;
}
.front-face {
  transform: rotateY(0deg);
}
.back-face {
  transform: rotateY(180deg);
}
.ticket-card:focus-visible .card-visual {
  outline: 1px solid rgba(0, 0, 0, 0.24);
  outline-offset: 5px;
}
.face-fallback {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 100%;
  padding: 12px;
  text-align: center;
  color: #777;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(0, 0, 0, 0.12);
  font-size: 9px;
  line-height: 1.5;
  backface-visibility: hidden;
}
.face-fallback strong {
  font-size: 19px;
  font-weight: 400;
  color: #777;
}
.empty-state {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  text-align: center;
  z-index: 2;
  color: #292929;
  pointer-events: none;
}
.empty-state strong {
  font-weight: 500;
  font-size: 15px;
}
.empty-state span {
  font-size: 11px;
  color: #999;
}
.detail-popover {
  position: absolute;
  z-index: 12;
  left: 16px;
  top: 16px;
  opacity: 0;
  transform: translateY(5px);
  pointer-events: none;
  transition:
    opacity 0.18s ease,
    transform 0.18s ease;
}
.detail-popover.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.popover-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}
.popover-header button {
  width: 23px;
  height: 23px;
  border: 0;
  border-radius: 50%;
  background: #f3f3f2;
  color: #666;
  font-size: 17px;
  line-height: 1;
}
.popover-heading h2 {
  color: #202020;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.popover-id {
  font-size: 9px;
  color: #999;
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
}
.popover-facts {
  grid-template-columns: 1fr 1fr;
}
.popover-facts div {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.popover-facts b {
  color: #444;
  overflow: hidden;
  text-overflow: ellipsis;
}
.popover-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.popover-bottom > span {
  font-size: 9px;
  color: #888;
}
.popover-bottom div {
  display: flex;
  gap: 6px;
}
.popover-bottom button {
  border: 1px solid #e5e5e3;
  border-radius: 5px;
  background: #fff;
  padding: 6px 8px;
  color: #555;
  font-size: 9px;
}
.popover-bottom button:hover {
  background: #f3f3f2;
  border-color: #c8c8c6;
  color: #222;
}
.popover-bottom #markBtn.is-marked {
  color: #111;
  background: #eee;
  border-color: #ccc;
}
@media (max-width: 1100px) {
  .app-shell {
    grid-template-columns: 250px minmax(0, 1fr);
  }
  .sidebar {
    padding: 24px 18px;
  }
  .detail-popover {
    width: 248px;
  }
}
@media (max-width: 740px) {
  .app-shell {
    grid-template-columns: minmax(0, 1fr);
  }
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: min(300px, 86vw);
    height: 100dvh;
    z-index: 42;
    transform: translateX(-105%);
    transition: transform 0.28s cubic-bezier(0.2, 0.72, 0.18, 1);
    box-shadow: 12px 0 38px rgba(0, 0, 0, 0.09);
    padding: 22px 18px 26px;
  }

  .detail-popover {
    left: 12px;
    right: 12px;
    top: auto;
    bottom: 12px;
    width: auto;
    max-width: none;
    margin: 0;
    padding: 13px 14px 11px;
    border-radius: 8px;
  }
}
@media (max-width: 390px) {
  .sidebar {
    padding-left: 16px;
    padding-right: 16px;
  }
  .detail-popover {
    bottom: 10px;
  }
  .popover-facts {
    gap: 8px;
  }
  .popover-bottom button {
    padding: 6px 7px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
  .ticket-card.focus-card {
    will-change: auto;
  }
}
.boot-error {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(248, 248, 247, 0.96);
  color: #222;
}
.boot-error[hidden] {
  display: none !important;
}
.boot-error-card {
  width: min(520px, 100%);
  padding: 26px 28px;
  border: 1px solid #e4e4e1;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 16px 50px rgba(0, 0, 0, 0.07);
}
.boot-error-card strong {
  display: block;
  font-size: 16px;
  font-weight: 650;
}
.boot-error-card p {
  margin: 12px 0;
  color: #555;
  font-size: 13px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.boot-error-card small {
  color: #999;
  font-size: 11px;
}
.app-shell {
  display: block !important;
}
.sidebar {
  display: none !important;
  position: fixed !important;
  inset: 190px 80px auto auto !important;
  max-height: calc(100vh - 220px) !important;
  background: #fff !important;
  border: 1px solid #282626 !important;
  box-shadow: none !important;
  z-index: 20 !important;
  transform: none !important;
}
.filter-open .sidebar,
.layout-open .sidebar {
  display: block !important;
}
.filter-open .side-section:not(.filter-section) {
  display: none !important;
}
.layout-open .filter-section {
  display: none !important;
}
.sidebar .side-section {
  border: 0 !important;
  padding: 0 0 18px !important;
}
.tools {
  position: fixed;
  right: 28px;
  top: 190px;
  display: flex;
  flex-direction: column;
  gap: 9px;
  z-index: 25;
}
.tools button {
  width: 36px;
  height: 36px;
  border: 1px solid #282626;
  background: #fff;
  font-size: 24px;
  cursor: pointer;
}
.viewport,
.canvas-stage {
  width: 100% !important;
}
.batches {
  font-size: 12px;
  margin: 20px 0;
}
.batches button {
  background: white;
  border: 1px solid #aaa;
  padding: 8px;
}
.detail-popover {
  border-radius: 0 !important;
  border: 1px solid #282626 !important;
  box-shadow: none !important;
}
#showDetails {
  padding: 6px;
  background: white;
  border: 1px solid #222;
  cursor: pointer;
}
.boot-error {
  z-index: 100;
}
.composition {
  border-radius: 0 !important;
}
@media (max-width: 700px) {
  .sidebar {
    inset: 160px 62px auto 16px !important;
  }
}
.sidebar {
  height: auto !important;
}
.workspace {
  width: 100% !important;
}
.side-section button,
.sidebar select {
  border-radius: 0 !important;
}
.viewport {
  background: #fff;
}
.viewport::before,
.viewport::after {
  display: none;
}
.canvas-stage {
  width: 100% !important;
}
@media (max-width: 700px) {
  .viewport {
    margin-left: 0;
    width: 100% !important;
  }
  .viewport:before {
    display: block;
    z-index: 3;
    inset: 0 auto 0 0;
    width: 120px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.95), transparent);
  }
}
.sidebar {
  top: 196px !important;
  right: 80px !important;
  width: 290px !important;
  padding: 22px !important;
  animation: panel-in 0.18s ease-out;
}
.sidebar h2 {
  font-size: 16px;
  font-weight: 400;
  margin: 0 0 22px;
}
.sidebar .filter-fields label {
  font-size: 13px;
  color: #555;
  margin-bottom: 18px;
  gap: 9px;
}
.sidebar .filter-fields select {
  font-size: 13px;
  height: auto;
  padding: 10px;
  border: 1px solid #aaa;
  color: #282626;
}
.sidebar .text-action {
  border-bottom: 1px solid #282626;
  color: #282626;
}
.detail-popover {
  font-family: ui-monospace, SFMono-Regular, Menlo, "PingFang SC", sans-serif;
  background: #fff;
}
.popover-facts b {
  font-weight: 400;
}
.popover-facts {
  margin-top: 18px;
  border-bottom: 0;
}
.popover-facts div:last-child {
  grid-column: auto;
}
.popover-bottom {
  padding-top: 8px;
}
.popover-bottom #showDetails {
  font: inherit;
  border: 1px solid #282626;
  border-radius: 0;
  background: #fff;
  color: #282626;
}
.popover-header #popoverClose {
  border: 0;
  background: transparent;
  border-radius: 0;
  color: #282626;
}
.reset-section {
  display: none;
}
.reset-open .sidebar {
  display: block !important;
}
.reset-open .sidebar .side-section {
  display: none !important;
}
.reset-open .sidebar .reset-section {
  display: block !important;
}
@media (max-width: 700px) {
  .sidebar {
    top: 150px !important;
    right: 66px !important;
    left: auto !important;
    width: min(290px, calc(100vw - 82px)) !important;
    max-height: calc(100dvh - 170px) !important;
  }
  .tools {
    top: 150px !important;
    right: 16px !important;
  }
}
.scene > .ticket-card {
  transition:
    transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1),
    width 0.3s ease,
    height 0.3s ease,
    opacity 0.18s ease;
}
@media (prefers-reduced-motion: reduce) {
  .scene > .ticket-card {
    transition: none !important;
  }
}
.viewport {
  margin-left: 0 !important;
  width: 100% !important;
}
.viewport::before {
  display: block !important;
  inset: 22px auto auto 24px !important;
  width: 323px;
  height: 150px;
  background: #fff !important;
  z-index: 6;
  pointer-events: none;
}
.detail-popover {
  width: 304px !important;
  padding: 20px !important;
}
.popover-header {
  align-items: center;
  margin: 0 0 12px !important;
  padding: 0 !important;
}
.popover-category {
  font-size: 12px !important;
  letter-spacing: 0.04em !important;
  color: #666 !important;
}
.popover-header #popoverClose {
  width: 24px;
  height: 24px;
  padding: 0;
  display: grid;
  place-items: center;
  font-size: 22px !important;
}
.popover-heading {
  margin: 0 !important;
}
.popover-heading h2 {
  font-size: 20px !important;
  line-height: 1.5 !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
  margin: 0 !important;
  overflow-wrap: anywhere;
}
.popover-facts {
  display: flex !important;
  flex-direction: column;
  gap: 12px !important;
  border-top: 1px solid #ddd !important;
  padding: 18px 0 !important;
  margin: 18px 0 0 !important;
}
.popover-facts > div {
  display: grid !important;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 12px !important;
  align-items: start;
}
.popover-facts span {
  font-size: 12px !important;
  line-height: 1.6;
  color: #777 !important;
}
.popover-facts b {
  font-size: 14px !important;
  line-height: 1.6;
  white-space: normal !important;
  overflow-wrap: anywhere;
}
.popover-bottom {
  padding: 0 !important;
  margin-top: 2px;
}
.popover-bottom #showDetails {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 13px !important;
  font-size: 14px !important;
  text-align: left;
}
.sidebar .select-trigger {
  font-family: inherit;
  font-size: 13px;
  min-height: 42px;
}
.tools > button:focus-visible {
  outline: 2px solid #d40909;
  outline-offset: 3px;
}
@media (max-width: 700px) {
  .viewport::before {
    left: 8px !important;
    top: 12px !important;
    width: 206px !important;
    height: 100px;
  }
  .detail-popover {
    width: auto !important;
    max-width: calc(100% - 24px);
  }
}
