:root {
  --bg:#f9f8f6;
  --paper:#fff;
  --ink:#26251f;
  --muted:#68665e;
  --line:#dedbd4;
  --wash:#f0efea;
  --accent:#ad4929;
  --clay:#d86b42;
  --pale:#fdf2ee;
  --shadow:0 12px 40px #33281412;
  color-scheme:light;
  font:15px/1.55 Inter,"Segoe UI",Arial,sans-serif;
}
:root.dark {
  --bg:#201e1b;
  --paper:#292722;
  --ink:#f6f2eb;
  --muted:#bcb5aa;
  --line:#49443d;
  --wash:#332f29;
  --accent:#f3aa87;
  --clay:#d86b42;
  --pale:#422e25;
  --shadow:0 12px 40px #0003;
  color-scheme:dark;
}
* {
  box-sizing:border-box;
}
body {
  margin:0;
  color:var(--ink);
  background:var(--bg);
}
header,footer {
  display:flex;
  align-items:center;
  gap:18px;
  padding:15px clamp(18px,5vw,84px);
  border-bottom:1px solid var(--line);
}
header {
  min-height:74px;
  justify-content:space-between;
}
footer {
  margin-top:auto;
  border-bottom:0;
  border-top:1px solid var(--line);
  font-size:13px;
  color:var(--muted);
}
footer span {
  margin-right:auto;
}
body {
  min-height:100vh;
  display:flex;
  flex-direction:column;
}
main {
  width:100%;
  max-width:1520px;
  margin:0 auto;
  padding:clamp(20px,4vw,64px) clamp(18px,5vw,84px);
  flex:1;
}
h1,h2,h3,p {
  margin:0 0 14px;
}
h1,h2 {
  font-family:Georgia,"Times New Roman",serif;
  font-weight:500;
  letter-spacing:-.045em;
  line-height:1.08;
}
h1 {
  font-size:clamp(38px,5vw,72px);
}
h2 {
  font-size:32px;
}
h3 {
  font-size:16px;
}
p,small {
  color:var(--muted);
}
button,.btn,input,select,textarea {
  font:inherit;
  color:inherit;
}
button,.btn,select {
  cursor:pointer;
}
button,.btn {
  background:var(--paper);
  border:1px solid var(--line);
  border-radius:8px;
  padding:8px 14px;
  text-decoration:none;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
}
button:hover,.btn:hover {
  border-color:var(--accent);
  color:var(--accent);
}
button:disabled {
  opacity:.45;
  cursor:default;
}
.primary {
  background:var(--accent);
  border-color:var(--accent);
  color:var(--paper);
  font-weight:650;
}
.primary:hover {
  background:var(--ink);
  color:var(--paper);
}
.plain,.brand {
  border:0;
  background:transparent;
}
.brand {
  font-size:21px;
  font-weight:750;
  letter-spacing:-.06em;
  padding:0;
  gap:10px;
}
.mark {
  display:grid;
  place-items:center;
  background:var(--clay);
  color:white;
  border-radius:9px;
  width:32px;
  height:32px;
  font-family:Georgia;
  font-weight:bold;
}
nav,.actions,.controls,.crumb,.row {
  display:flex;
  align-items:center;
  gap:9px;
  flex-wrap:wrap;
}
a {
  color:var(--accent);
}
svg {
  width:19px;
  height:19px;
  stroke:currentColor;
  fill:none;
  stroke-width:1.7;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.hero {
  display:grid;
  grid-template-columns:1.15fr .85fr;
  align-items:center;
  gap:7%;
  min-height:60vh;
}
.hero h1 {
  font-size:clamp(54px,6.8vw,106px);
  letter-spacing:-.07em;
}
.hero h1 em {
  color:var(--accent);
  font-weight:400;
}
.hero p {
  max-width:490px;
  font-size:18px;
  margin:22px 0 28px;
}
.art {
  background:var(--wash);
  border-radius:24px;
  min-height:315px;
  display:grid;
  place-items:center;
  position:relative;
  overflow:hidden;
}
.art:before {
  content:"";
  position:absolute;
  width:330px;
  height:330px;
  border:1px dashed var(--line);
  border-radius:50%;
  transform:rotate(-23deg);
}
.artFolder {
  width:66%;
  height:155px;
  background:var(--clay);
  border-radius:8px 16px 16px 16px;
  transform:rotate(-7deg);
  box-shadow:10px 17px 0 #9d4b2b29;
  position:relative;
  display:flex;
  align-items:flex-end;
  padding:20px;
  color:#411f15;
  font:italic 25px Georgia;
}
.artFolder:before {
  content:"";
  position:absolute;
  top:-19px;
  left:0;
  width:43%;
  height:24px;
  background:var(--clay);
  border-radius:9px 16px 0 0;
}
.artFolder:after {
  content:"";
  position:absolute;
  background:var(--paper);
  border:1px solid var(--line);
  left:10%;
  top:-9px;
  width:80%;
  height:9px;
  transform:rotate(2deg);
  border-radius:4px;
}
.features {
  display:grid;
  grid-template-columns:repeat(3,1fr);
  border-top:1px solid var(--line);
  gap:28px;
  padding-top:26px;
}
.features svg {
  color:var(--accent);
  margin-bottom:8px;
}
.features p {
  margin:0;
}
.panel,dialog {
  background:var(--paper);
  border:1px solid var(--line);
  border-radius:16px;
  padding:24px;
}
.auth,.legal {
  max-width:490px;
  margin:4vh auto;
}
.legal {
  max-width:740px;
}
.auth h1,.workspace h1 {
  font-size:clamp(34px,4vw,52px);
}
label {
  display:grid;
  gap:6px;
  font-size:14px;
  font-weight:600;
  margin-bottom:14px;
}
input,textarea,select {
  background:var(--paper);
  border:1px solid var(--line);
  border-radius:7px;
  padding:9px 12px;
  min-width:0;
}
input:focus,textarea:focus,select:focus,button:focus-visible,a:focus-visible {
  outline:2px solid var(--clay);
  outline-offset:2px;
}
form .primary {
  margin-top:5px;
}
textarea {
  width:100%;
  min-height:180px;
  font-family:ui-monospace,monospace;
}
.shell {
  display:grid;
  grid-template-columns:225px minmax(0,1fr);
  gap:clamp(18px,3vw,46px);
}
.side {
  border-right:1px solid var(--line);
  padding-right:20px;
}
.side button,.side select {
  width:100%;
  text-align:left;
  justify-content:start;
  margin:3px 0;
}
.side .current {
  color:var(--accent);
  background:var(--pale);
  border-color:transparent;
}
.side .meter {
  margin-top:32px;
}
.meter progress,.job progress {
  width:100%;
  accent-color:var(--clay);
}
.crumb {
  gap:4px;
  color:var(--muted);
  font-size:13px;
  margin-bottom:16px;
}
.crumb button {
  padding:1px 4px;
}
.workspace h1 {
  overflow-wrap:anywhere;
}
.workspace .actions {
  margin:16px 0;
}
.drop {
  border:1px dashed var(--clay);
  background:var(--pale);
  border-radius:12px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:12px;
  width:100%;
  padding:20px;
  margin:18px 0;
  color:var(--accent);
}
.drag {
  outline:3px solid var(--clay);
}
.controls {
  justify-content:space-between;
  margin:20px 0 14px;
}
.controls form {
  display:flex;
  gap:4px;
  flex:1;
}
.controls input {
  width:min(100%,270px);
}
.files {
  display:grid;
  gap:8px;
}
.files.grid {
  grid-template-columns:repeat(auto-fill,minmax(175px,1fr));
}
.file {
  background:var(--paper);
  border:1px solid var(--line);
  border-radius:10px;
  padding:10px;
  display:flex;
  align-items:center;
  gap:8px;
  min-width:0;
}
.file .open {
  flex:1;
  min-width:0;
  display:flex;
  justify-content:start;
  text-align:left;
  gap:13px;
}
.type {
  display:inline-grid;
  place-items:center;
  border-radius:9px;
  background:var(--wash);
  color:var(--accent);
  padding:9px;
}
.filename {
  min-width:0;
  overflow-wrap:anywhere;
  line-height:1.3;
}
.filename small {
  display:block;
  margin-top:4px;
}
.grid .open {
  align-items:start;
  flex-direction:column;
}
.grid .file {
  align-items:flex-start;
}
.file .more {
  padding:5px;
}
.empty {
  text-align:center;
  padding:35px 16px;
  color:var(--muted);
  border:1px solid var(--line);
  border-radius:12px;
}
.subtle {
  font-size:13px;
  color:var(--muted);
}
.danger {
  color:var(--accent);
}
dialog {
  color:var(--ink);
  width:min(540px,94vw);
  max-height:85vh;
  overflow:auto;
  box-shadow:var(--shadow);
}
dialog::backdrop {
  background:#211e1b72;
}
.dialoghead {
  display:flex;
  justify-content:space-between;
  align-items:start;
  gap:10px;
  margin-bottom:14px;
}
.dialoghead h2 {
  font-size:28px;
  overflow-wrap:anywhere;
}
.dialoghead button {
  padding:3px 9px;
}
dialog pre {
  white-space:pre-wrap;
  overflow-wrap:anywhere;
  max-height:50vh;
  overflow:auto;
}
dialog img,dialog iframe {
  width:100%;
  max-height:55vh;
  object-fit:contain;
}
dialog iframe {
  height:50vh;
  border:0;
}
#notice:not(:empty),#transfers {
  position:fixed;
  z-index:5;
  right:18px;
  bottom:18px;
  background:var(--ink);
  color:var(--paper);
  border-radius:10px;
  padding:14px 18px;
  max-width:min(450px,92vw);
  box-shadow:var(--shadow);
}
#transfers {
  bottom:75px;
  background:var(--paper);
  color:var(--ink);
  border:1px solid var(--line);
  width:340px;
  max-height:42vh;
  overflow:auto;
}
.job {
  margin:10px 0;
  overflow-wrap:anywhere;
}
.buttons {
  display:grid;
  gap:7px;
}
.buttons button {
  justify-content:start;
}
.error {
  color:var(--accent);
  font-weight:600;
}
.stack>*+* {
  margin-top:12px;
}
[hidden] {
  display:none!important;
}
@media(max-width:760px) {
  .hero,.shell {
    grid-template-columns:1fr;
  }
  .hero {
    gap:25px;
  }
  .art {
    min-height:210px;
  }
  .artFolder {
    height:100px;
    width:50%;
  }
  .features {
    margin-top:28px;
    grid-template-columns:1fr;
  }
  .side {
    border-right:0;
    border-bottom:1px solid var(--line);
    padding:0 0 12px;
    display:flex;
    flex-wrap:wrap;
    gap:6px;
  }
  .side button,.side select {
    width:auto;
  }
  .side label {
    width:100%;
    margin:0;
  }
  .side .meter {
    margin:0;
    width:100%;
  }
  .side progress {
    max-width:150px;
  }
  .controls form {
    flex-basis:100%;
  }
  .controls input {
    flex:1;
  }
  header {
    padding:12px 16px;
    gap:10px;
  }
  nav {
    gap:4px;
  }
  nav button {
    padding:5px 8px;
  }
  .file {
    padding:6px;
  }
  .features {
    gap:12px;
  }
  .panel {
    padding:18px;
  }
  .actions button {
    font-size:14px;
  }
}
dialog canvas {
  display:block;
  max-width:100%;
  height:auto;
  margin:auto;
}
.file .open>.row {
  flex-wrap:nowrap;
  min-width:0;
}
.grid .file .open>.row {
  flex-direction:column;
  align-items:start;
}
