.pane { padding: 12px; font-family: 'Segoe UI', sans-serif; }
h2 { margin: 0 0 4px; font-size: 17px; }
.hint { margin: 0 0 10px; font-size: 12px; color: #605e5c; }

.editor {
  position: relative; display: flex; height: 260px; overflow: hidden;
  border: 1px solid #c8c6c4; border-radius: 4px; background: #fbfbfa;
  font-family: Consolas, 'Courier New', monospace;
  font-size: 11.5px; line-height: 1.5;
}
.gutter {
  flex: 0 0 38px; padding: 8px 6px 8px 0; overflow: hidden;
  border-right: 1px solid #e1dfdd; background: #f3f2f1;
  color: #8a8886; text-align: right; white-space: pre; user-select: none;
}
.code { position: relative; flex: 1; min-width: 0; }
.mirror, .code textarea {
  position: absolute; inset: 0; margin: 0; padding: 8px;
  font: inherit; line-height: inherit;
  white-space: pre; overflow: auto;
  border: 0; outline: 0; box-sizing: border-box;
}
.mirror { pointer-events: none; color: #24292e; }
.mirror .row { min-height: 1.5em; }
.code textarea {
  background: transparent; color: transparent;
  caret-color: #201f1e; resize: none;
}
.t-txt { color: #24292e; }
.t-brk { color: #0f766e; font-weight: 700; }
.t-nam { color: #0f5fc4; font-weight: 700; }
.t-att { color: #7c3aed; }
.t-val { color: #9d174d; }
.t-op  { color: #64748b; }
.t-com { color: #2f6b3f; font-style: italic; }
.t-doc { color: #b45309; font-weight: 700; }

.strip {
  display: flex; align-items: center; gap: 6px;
  margin: 5px 2px 0; font-size: 11px; color: #8a8886;
}
.strip #count { margin-left: auto; }
.dot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 auto; }
.dot.idle  { background: #c8c6c4; }
.dot.clean { background: #107c10; }
.dot.dirty { background: #ca5010; }

.go { width: 100%; height: 38px; font-size: 14px; margin-top: 10px; }
.upd { width: 100%; height: 34px; font-size: 13px; margin-top: 6px; }
.status { margin-top: 8px; font-size: 12px; color: #605e5c; min-height: 16px; }
.status.busy { color: #0078d4; font-weight: 600; }
.row2 { display: flex; gap: 8px; margin-top: 10px; }
.row2 button { flex: 1; }

#log { margin-top: 12px; max-height: 140px; overflow: auto; font-size: 11.5px; font-family: Consolas, monospace; }
#log .line { padding: 3px 6px; border-radius: 3px; margin-bottom: 2px; }
#log .ok { background: #dff6dd; color: #107c10; }
#log .err { background: #fde7e9; color: #a4262c; }
#log .info { background: #f3f2f1; color: #323130; }

.gallery {
  display: none; position: fixed; inset: 0; z-index: 90;
  align-items: center; justify-content: center; padding: 14px;
}
.gallery-backdrop { position: absolute; inset: 0; background: rgba(32, 31, 30, 0.45); }
.gallery-panel {
  position: relative; display: flex; flex-direction: column;
  width: 100%; max-width: 420px; max-height: 100%;
  overflow: hidden; border-radius: 8px; background: #ffffff;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.26);
}
.gallery-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 12px; padding: 14px 16px 12px; border-bottom: 1px solid #edebe9;
}
.gallery-kicker {
  margin: 0 0 2px; font-size: 10px; font-weight: 700; color: #8a8886;
  text-transform: uppercase; letter-spacing: .09em;
}
.gallery-title { margin: 0; font-size: 16px; color: #201f1e; }
.gallery-x {
  flex: 0 0 auto; width: 26px; height: 26px; padding: 0;
  border: 0; border-radius: 4px; background: transparent;
  color: #605e5c; font-size: 19px; line-height: 1; cursor: pointer;
}
.gallery-x:hover { background: #f3f2f1; color: #201f1e; }

.chips {
  display: flex; flex-wrap: wrap; gap: 5px;
  padding: 10px 16px 0;
}
.chip {
  padding: 4px 10px; border: 1px solid #e1dfdd; border-radius: 999px;
  background: #faf9f8; color: #605e5c;
  font-family: inherit; font-size: 11px; cursor: pointer;
}
.chip:hover { border-color: #0078d4; color: #0078d4; }
.chip.on { background: #201f1e; border-color: #201f1e; color: #ffffff; }

.gallery-list {
  flex: 1; min-height: 0; overflow: auto;
  display: flex; flex-direction: column; gap: 8px; padding: 12px 16px 14px;
}
.sample {
  display: flex; flex-direction: column; gap: 3px;
  padding: 11px 13px; text-align: left; cursor: pointer;
  border: 1px solid #e1dfdd; border-radius: 6px; background: #faf9f8;
  font-family: inherit; transition: border-color .15s, background .15s;
}
.sample:hover { border-color: #0078d4; background: #f3f9fd; }
.sample-name { font-size: 13px; font-weight: 600; color: #201f1e; }
.sample-desc { font-size: 11.5px; color: #605e5c; line-height: 1.35; margin: 0; }

.gallery-foot { padding: 10px 16px 14px; border-top: 1px solid #edebe9; background: #faf9f8; }
.lib-row { align-items: center; gap: 8px; margin-bottom: 9px; }
.lib-note { flex: 1; font-size: 10.5px; color: #8a8886; }
.gallery-links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.gallery-links:first-child { margin-top: 0; }
.link-btn {
  padding: 6px 11px; border: 1px solid #c8c6c4; border-radius: 999px;
  background: #ffffff; color: #201f1e; font-family: inherit;
  font-size: 11.5px; cursor: pointer;
}
.link-btn:hover { border-color: #0078d4; color: #0078d4; }

[hidden]{display:none!important}body{font:14px/1.5 "Segoe UI",sans-serif;margin:0;color:#173632}.account,.manage{padding:16px;background:#eef6f3}.account strong{font-size:18px}.account button,.manage button{padding:7px 12px;cursor:pointer}.manage{max-width:700px;margin:5vh auto}.manage section{background:white;padding:16px;margin:12px 0}.manage input{padding:8px;width:min(310px,85%)}a{color:#005b49}code{overflow-wrap:anywhere}
/* Welcome screen */
.account{position:relative;isolation:isolate;min-height:100vh;box-sizing:border-box;overflow:hidden;padding:0;background:radial-gradient(ellipse at 90% 17%,#234e65 0%,transparent 42%),linear-gradient(155deg,#071e2d 0%,#102e3d 59%,#063c3d 100%);color:#f6fcfb}
.account::before{content:"";position:absolute;inset:0;z-index:-1;opacity:.27;background-image:linear-gradient(#ffffff13 1px,transparent 1px),linear-gradient(90deg,#ffffff13 1px,transparent 1px);background-size:32px 32px;mask-image:linear-gradient(to bottom,#000,transparent 75%)}
.account::after{content:"";position:absolute;width:290px;height:290px;right:-130px;top:75px;border-radius:50%;background:#49d7ba;filter:blur(95px);opacity:.16;z-index:-1}
.account-content{position:relative;z-index:2;display:flex;flex-direction:column;min-height:100vh;box-sizing:border-box;padding:24px clamp(20px,7vw,34px) 25px}
.brand{display:flex;align-items:center;gap:10px;font-size:10px;font-weight:750;letter-spacing:.16em;color:#f5fffd;white-space:nowrap}.brand-mark{display:grid;place-items:center;width:29px;height:29px;border:1px solid #b2f0df66;border-radius:9px;background:#7de5c921;color:#b1f9e2;font-size:19px;letter-spacing:-.1em}.brand-mark span{color:#52d5b4}.brand-sub{color:#a8c5c6;font-weight:500}
.welcome-art{position:absolute;right:-23px;top:75px;width:180px;height:175px;pointer-events:none;opacity:.84}.art-orbit{position:absolute;inset:1px 1px 2px 8px;border:1px solid #a4f4d72e;border-radius:50%;transform:rotate(-24deg) scaleX(1.35)}.art-slide{position:absolute;width:113px;height:73px;border:1px solid #9eeed7aa;border-radius:8px;box-shadow:0 12px 33px #001b2799}.art-slide-back{left:27px;top:32px;background:#356879;transform:rotate(-15deg)}.art-slide-front{left:45px;top:56px;background:linear-gradient(145deg,#baf6dd,#59cdb6);transform:rotate(9deg);padding:14px;box-sizing:border-box}.art-slide-front i{display:block;height:5px;width:65%;border-radius:4px;background:#0a575d;margin-bottom:7px}.art-slide-front i:first-child{width:80%;height:8px}.art-slide-front i:last-child{width:42%}.art-spark{position:absolute;top:16px;right:27px;color:#adf6d6;font-size:23px}
.welcome{margin-top:clamp(96px,21vh,150px)}.eyebrow{display:flex;align-items:center;gap:8px;color:#a8eacb;font-size:10px;font-weight:700;letter-spacing:.19em}.eyebrow-dot{width:6px;height:6px;background:#83e6bd;border-radius:50%;box-shadow:0 0 13px #83e6bd}.welcome h1{font-size:clamp(29px,8vw,43px);line-height:1.14;letter-spacing:-.045em;margin:16px 0 14px;max-width:380px}.welcome h1 em{font-style:normal;color:#9af0cb}.welcome-copy{font-size:14px;line-height:1.6;color:#b9d1d2;max-width:300px;margin:0 0 27px}.trial-line{display:flex;align-items:flex-start;gap:10px;padding:14px 0;border-top:1px solid #b7e1db36;color:#e1f5ee;font-size:13px;line-height:1.5}.trial-icon{color:#a8f2ce;font-size:15px}
.account #login{display:flex;align-items:center;gap:11px;width:100%;min-height:49px;box-sizing:border-box;margin-top:15px;padding:11px 16px;border:1px solid #d7efea;border-radius:9px;background:#f8fffc;color:#15383d;font:600 13px "Segoe UI",sans-serif;box-shadow:0 12px 28px #001a244d;transition:transform .18s,box-shadow .18s,background .18s}.account #login:hover{transform:translateY(-2px);background:white;box-shadow:0 17px 30px #001a2470}.account #login:focus-visible{outline:3px solid #86f2d2;outline-offset:3px}.account #login:disabled{opacity:.6;cursor:wait;transform:none}.button-arrow{margin-left:auto;font-size:20px;font-weight:400}.ms-symbol{display:grid;grid-template-columns:repeat(2,7px);gap:2px}.ms-symbol i{display:block;width:7px;height:7px;background:#f35325}.ms-symbol i:nth-child(2){background:#81bc06}.ms-symbol i:nth-child(3){background:#05a6f0}.ms-symbol i:nth-child(4){background:#ffba08}.welcome-foot{margin:auto 0 0;padding-top:32px;color:#8fb1b3;font-size:11px;letter-spacing:.02em}
body.authenticated .account{min-height:0;background:#eef6f3;color:#173632}body.authenticated .account-content{min-height:0;padding:15px 16px}body.authenticated .brand,body.authenticated .brand-sub{color:#173632}body.authenticated .brand-mark{background:#e1f7ee;color:#076b5b;border-color:#a2d5c5}body.authenticated .welcome-art,body.authenticated .welcome-copy,body.authenticated .eyebrow,body.authenticated .welcome h1,body.authenticated .welcome-foot{display:none}body.authenticated .welcome{margin:8px 0 0}body.authenticated .trial-line{padding:7px 0;border:0;color:#173632}body.authenticated .account::before,body.authenticated .account::after{display:none}
@media(max-height:440px){.welcome{margin-top:55px}.welcome-art{transform:scale(.7);transform-origin:top right}.welcome-copy{margin-bottom:12px}.account-content{padding-bottom:14px}.welcome-foot{padding-top:12px}}
@media(prefers-reduced-motion:reduce){.account #login{transition:none}}
.account #login[hidden]{display:none!important}

body.authenticated { background: #f4f9f7; }
#editor .pane { background: #f4f9f7; color: #173632; }
#editor .hint { color: #324f4b; line-height: 1.5; font-size: 13px; }
#editor .strip {
  flex-wrap: wrap;
  padding: 8px 10px;
  margin: 6px 0 0;
  border-radius: 6px;
  background: #e0efea;
  color: #224b44;
  font-size: 12px;
  line-height: 1.45;
}
#editor #count { white-space: nowrap; font-variant-numeric: tabular-nums; }
#editor .dot.idle { background: #56766e; }
