body { min-height: 100vh; }
.small { font-size: 12.5px; }

.top {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 16px clamp(16px, 4vw, 40px); border-bottom: 1px solid var(--line);
  position: sticky; top: 0; background: rgba(15, 14, 13, .88); backdrop-filter: blur(10px); z-index: 5;
}
.top-actions { display: flex; gap: 10px; }

main {
  display: grid; grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 32px;
  padding: 28px clamp(16px, 4vw, 40px) 60px; max-width: 1400px; margin: 0 auto;
}
@media (max-width: 900px) { main { grid-template-columns: 1fr; } }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 22px; }
.create { align-self: start; position: sticky; top: 92px; }
@media (max-width: 900px) { .create { position: static; } }
.create h2 { font-size: 24px; }
.create > p { margin: 4px 0 18px; font-size: 14px; }

.drops { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.drop {
  position: relative; aspect-ratio: 1; border: 1.5px dashed #4a443d; border-radius: var(--radius);
  display: grid; place-items: center; cursor: pointer; overflow: hidden; background: var(--surface-2);
  transition: border-color .15s ease, background .15s ease;
}
.drop:hover, .drop.over { border-color: var(--accent); background: #2a2420; }
.drop-empty { display: grid; gap: 4px; text-align: center; padding: 12px; font-size: 13px; }
.drop-icon { font-size: 26px; color: var(--accent); line-height: 1; margin-bottom: 4px; }
.drop-preview { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: none; }
.drop.filled { border-style: solid; border-color: var(--line); }
.drop.filled .drop-preview { display: block; }
.drop.filled .drop-empty { visibility: hidden; }

.realism { margin-top: 10px; padding: 10px 12px; background: var(--surface-2); border-radius: 10px; font-size: 14px; }
.realism ul { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 6px; }
.realism li { display: grid; grid-template-columns: 20px 1fr; gap: 4px; line-height: 1.4; }
.realism li::before { content: "✓"; color: var(--ok); font-weight: 700; }
.realism li.warn::before { content: "!"; color: var(--accent-2); text-align: center; }
.realism li span { font-size: 13px; }
.track { margin-top: 12px; padding: 10px 12px; background: var(--surface-2); border-radius: 10px; font-size: 14px; }

.fields { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 16px; align-items: end; }
.field { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.field.grow { flex: 1 1 100%; }
.field input[type=text], .field select {
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px;
  color: var(--text); font-size: 15px; outline: none;
}
.field input[type=text]:focus, .field select:focus { border-color: var(--accent); }
.field.check { display: flex; align-items: center; gap: 8px; padding-bottom: 10px; color: var(--text); }
.field.check input { accent-color: var(--accent); width: 16px; height: 16px; }

.create-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }

.lib-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 16px; }
.lib-head h2 { font-size: 24px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; }
.empty { padding: 40px 0; }

.exp { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; }
.exp.inactive .exp-thumb { filter: grayscale(1) brightness(.6); }
.exp-thumb { position: relative; aspect-ratio: 4/3; background: #000; cursor: pointer; }
.exp-thumb img, .exp-thumb video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.exp-thumb video { opacity: 0; transition: opacity .3s ease; }
.exp-thumb:hover video { opacity: 1; }
.exp-thumb .play {
  position: absolute; right: 10px; bottom: 10px; background: rgba(0,0,0,.6); border-radius: 999px;
  padding: 3px 10px; font-size: 12px;
}
.exp-body { padding: 12px 14px 14px; display: grid; gap: 8px; flex: 1; }
.exp-title { display: flex; justify-content: space-between; gap: 8px; align-items: start; }
.exp-title h3 { font-size: 17px; overflow-wrap: anywhere; }
.exp-meta { font-size: 12.5px; color: var(--muted); display: flex; gap: 10px; flex-wrap: wrap; }
.exp-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; }

.switch { position: relative; width: 38px; height: 22px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; background: #4a443d; border-radius: 999px; cursor: pointer; transition: background .2s; }
.switch span::after { content: ""; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .2s; }
.switch input:checked + span { background: var(--ok); }
.switch input:checked + span::after { transform: translateX(16px); }

dialog#preview {
  background: var(--surface); color: var(--text); border: 1px solid var(--line); border-radius: 20px;
  padding: 18px; width: min(920px, calc(100vw - 32px)); max-height: calc(100vh - 32px);
}
dialog::backdrop { background: rgba(0,0,0,.7); backdrop-filter: blur(4px); }
.pv-head, .pv-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.pv-foot { margin-top: 12px; justify-content: flex-start; }
.pv-stage { position: relative; margin-top: 12px; display: grid; place-items: center; background: #000; border-radius: 12px; overflow: hidden; }
.pv-stage img { display: block; max-width: 100%; max-height: 68vh; }
.pv-stage video { position: absolute; transition: opacity .3s ease; }
.pv-stage.art-only video { opacity: 0; }

/* Website additions */
.center { display: grid; place-items: center; padding: 48px 16px; }
.center .notice { max-width: 560px; }
.login-card { width: min(400px, 100%); display: grid; gap: 14px; }
.login-card h2 { font-size: 24px; }
.login-card p { margin: 0; }
.field input[type=email], .field input[type=password], .field textarea {
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px;
  color: var(--text); font-size: 16px; outline: none; width: 100%;
}
.field textarea { resize: vertical; font: inherit; font-size: 15px; }
.field input:focus, .field textarea:focus { border-color: var(--accent); }
.field em { font-style: normal; font-size: 12px; }
.error { color: var(--danger); min-height: 1.2em; font-size: 14px; }
.drop:focus-within { border-color: var(--accent); }
.realism { margin-top: 10px; padding: 10px 12px; background: var(--surface-2); border-radius: 10px; font-size: 14px; }
.realism ul { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 6px; }
.realism li { display: grid; grid-template-columns: 20px 1fr; gap: 4px; line-height: 1.4; }
.realism li::before { content: "✓"; color: var(--ok); font-weight: 700; }
.realism li.warn::before { content: "!"; color: var(--accent-2); text-align: center; }
.realism li span { font-size: 13px; }
.exp-meta .draft { color: var(--accent-2); }

dialog#qrDialog {
  background: var(--surface); color: var(--text); border: 1px solid var(--line); border-radius: 20px;
  padding: 18px; width: min(420px, calc(100vw - 32px));
}
.qr-wrap { background: #fff; border-radius: 12px; padding: 16px; margin: 14px 0 10px; display: grid; place-items: center; }
.qr-wrap canvas { width: 100%; max-width: 300px; height: auto; image-rendering: pixelated; }
.qr-link { word-break: break-all; margin: 0 0 12px; }
.qr-actions { display: flex; gap: 8px; flex-wrap: wrap; }
@media (max-width: 600px) {
  .top-actions { flex-wrap: wrap; }
  .create { padding: 16px; }
}

/* Match my print */
dialog#cropDialog {
  background: var(--surface); color: var(--text); border: 1px solid var(--line); border-radius: 20px;
  padding: 18px; width: min(720px, calc(100vw - 32px)); max-height: calc(100vh - 32px);
}
.crop-help { margin: 8px 0 12px; }
.crop-stage { position: relative; overflow: hidden; border-radius: 10px; background: #000; line-height: 0; }
.crop-stage img { display: block; width: 100%; height: auto; max-height: 55vh; object-fit: contain; }
.crop-box {
  position: absolute; border: 2px solid var(--accent-2); border-radius: 4px;
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, .6); transition: all .15s ease; pointer-events: none;
}
.field input[type=range] { accent-color: var(--accent); width: 100%; }
