/* An image editor of the late nineties, platinum chrome. The work is never filtered, warped or cropped. */
:root {
  --plat: #dddddd; --plat-l: #eeeeee; --plat-d: #bbbbbb; --plat-dd: #888888; --ink: #000;
  --menu-hi: #333399; --sel: #c9c9f4; --desk: #6b7591; --paste: #bdbdbd;
  --ui: "Charcoal", "Geneva", "Lucida Grande", "Tahoma", "Verdana", sans-serif;
  --small: "Geneva", "Verdana", "Tahoma", sans-serif;
  --menubar: 20px;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--desk); }
html { touch-action: manipulation; }
body { font: 11px/1.25 var(--small); color: var(--ink); -webkit-text-size-adjust: 100%; overscroll-behavior: none; }
button { font: inherit; color: inherit; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

.app { position: fixed; inset: 0; background: var(--desk); }
.checker { background-color: #fff; background-image: conic-gradient(#cccccc 25%, #fff 0 50%, #cccccc 0 75%, #fff 0); background-size: 16px 16px; }

/* ---------------- menu bar */
.menubar { position: absolute; left: 0; right: 0; top: 0; height: var(--menubar); display: flex; align-items: stretch; justify-content: space-between;
  background: linear-gradient(#f4f4f4, #dcdcdc); border-bottom: 1px solid #000; z-index: 50; font: 600 12px/19px var(--ui); user-select: none; -webkit-user-select: none; }
.menubar::before, .menubar::after { content: ""; position: absolute; top: 0; width: 6px; height: 6px; pointer-events: none; }
.menubar::before { left: 0; background: radial-gradient(circle at 6px 6px, transparent 5.5px, #000 6px); }
.menubar::after { right: 0; background: radial-gradient(circle at 0 6px, transparent 5.5px, #000 6px); }
.menus { display: flex; padding-left: 10px; min-width: 0; }
.mtitle { border: 0; background: none; padding: 0 9px; font: inherit; cursor: default; white-space: nowrap; }
.mtitle.open { background: var(--menu-hi); color: #fff; }
.mtitle:focus-visible { outline: 1px dotted #000; outline-offset: -3px; }
.menubar-right { display: flex; align-items: stretch; padding-right: 12px; }
.mb-user { border: 0; background: none; padding: 0 10px; font: inherit; cursor: default; }
.mb-user:hover, .mb-user:focus-visible { background: var(--menu-hi); color: #fff; outline: 0; }
.mb-clock { padding: 0 2px 0 8px; font-weight: 600; }

.menu-layer { position: fixed; left: 0; right: 0; bottom: 0; top: var(--menubar); z-index: 60; }
.menu { position: fixed; min-width: 190px; background: var(--plat-l); border: 1px solid #333; box-shadow: 2px 2px 0 rgba(0,0,0,.35); padding: 3px 0; font: 600 12px/18px var(--ui); }
.mi { display: flex; justify-content: space-between; gap: 22px; width: 100%; border: 0; background: none; padding: 0 14px 0 18px; text-align: left; font: inherit; cursor: default; white-space: nowrap; }
.mi .k { font-weight: 600; }
.mi.dis { color: #9a9a9a; }
.mi.chk::before { content: "\2713"; position: absolute; margin-left: -13px; }
.mi:not(.dis):hover, .mi:not(.dis):focus-visible { background: var(--menu-hi); color: #fff; outline: 0; }
.mi.sub::after { content: "\25B6"; font-size: 8px; }
.msep { height: 1px; margin: 4px 1px; background: #999; box-shadow: 0 1px #fff; }

/* ---------------- workspace and windows */
.workspace { position: absolute; left: 0; right: 0; top: var(--menubar); bottom: 0; }
.empty-ws { position: absolute; inset: 0; }
.win, .palette { position: absolute; background: var(--plat); border: 1px solid #222; box-shadow: 1px 1px 0 rgba(0,0,0,.4), inset 1px 1px #fff, inset -1px -1px #999; }

.wtitle { position: relative; height: 20px; display: flex; align-items: center; justify-content: center; padding: 0 6px; flex: none; user-select: none; -webkit-user-select: none; }
.wtitle::before { content: ""; position: absolute; left: 4px; right: 4px; top: 4px; bottom: 4px; background: repeating-linear-gradient(#fdfdfd 0 1px, #9c9c9c 1px 2px); }
.win:not(.front) .wtitle::before { background: none; }
.wtitle-text { position: relative; padding: 0 7px; background: var(--plat); font: 600 12px/20px var(--ui); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: calc(100% - 90px); }
.win:not(.front) .wtitle-text { color: #888; }
.wclose, .wbox { position: absolute; top: 4px; width: 13px; height: 12px; padding: 0; border: 1px solid #3a3a3a; background: linear-gradient(135deg, #a6a6a6, #f6f6f6 70%); box-shadow: 0 0 0 2px var(--plat), inset 1px 1px #fff; cursor: default; }
.wclose { left: 8px; }
.wclose:active { background: linear-gradient(135deg, #f6f6f6, #8a8a8a); }
.wclose::after { content: ""; position: absolute; inset: -12px; }
.wzoom { right: 26px; }
.wzoom::before { content: ""; position: absolute; left: 1px; top: 1px; width: 6px; height: 5px; border: 1px solid #555; }
.wshade { right: 8px; }
.wshade::before { content: ""; position: absolute; left: 1px; right: 1px; top: 4px; height: 0; border-top: 1px solid #555; border-bottom: 1px solid #555; padding-top: 1px; }
.win:not(.front) .wclose, .win:not(.front) .wbox { visibility: hidden; }

/* document window */
.docwin { display: flex; flex-direction: column; }
.docbody { position: relative; flex: 1; min-height: 0; display: grid; grid-template-columns: 16px minmax(0, 1fr) 15px; grid-template-rows: 16px minmax(0, 1fr); margin: 0 3px; border: 1px solid #555; border-bottom: 0; background: var(--paste); }
.rulers { display: contents; }
.ruler-corner { grid-column: 1; grid-row: 1; background: #fff; border-right: 1px solid #888; border-bottom: 1px solid #888; }
.ruler { display: block; width: 100%; height: 100%; background: #fff; }
.ruler-h { grid-column: 2; grid-row: 1; border-bottom: 1px solid #888; }
.ruler-v { grid-column: 1; grid-row: 2; border-right: 1px solid #888; }
.norulers .docbody { grid-template-columns: 0 minmax(0, 1fr) 15px; grid-template-rows: 0 minmax(0, 1fr); }
.norulers .ruler, .norulers .ruler-corner { visibility: hidden; }
.stage { grid-column: 2; grid-row: 2; position: relative; overflow: hidden; display: grid; place-items: center; background: var(--paste); touch-action: manipulation; }
.canvas { position: relative; box-shadow: 0 0 0 1px #4a4a4a; }
.canvas.solid { background: #000; }
.layer-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: block; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.layer-img[src=""], .layer-img:not([src]) { visibility: hidden; }
.ants { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.ants rect { fill: none; shape-rendering: crispEdges; stroke-width: 1; vector-effect: non-scaling-stroke; }
.ants .a1 { stroke: #fff; }
.ants .a2 { stroke: #000; stroke-dasharray: 4 4; animation: march .5s linear infinite; }
@keyframes march { to { stroke-dashoffset: -8; } }
.stage.t-move { cursor: default; }
.stage.t-marquee, .stage.t-other { cursor: crosshair; }
.stage.t-eyedropper { cursor: copy; }
.stage.t-hand { cursor: grab; }
.stage.t-zoom { cursor: zoom-in; }

.sb { display: flex; background: var(--plat); }
.vscroll { grid-column: 3; grid-row: 1 / span 2; flex-direction: column; border-left: 1px solid #555; }
.sb-track { flex: 1; background: var(--plat); }
.sb-up, .sb-down, .sb-left, .sb-right { flex: none; width: 14px; height: 14px; position: relative; background: linear-gradient(135deg, #f8f8f8, #c4c4c4); box-shadow: inset 1px 1px #fff, inset -1px -1px #999; }
.sb-up { border-bottom: 1px solid #555; } .sb-down { border-top: 1px solid #555; }
.sb-left { border-right: 1px solid #555; } .sb-right { border-left: 1px solid #555; }
.sb-up::after, .sb-down::after, .sb-left::after, .sb-right::after { content: ""; position: absolute; left: 50%; top: 50%; border: 3.5px solid transparent; opacity: .55; }
.sb-up::after { border-bottom: 4px solid #000; transform: translate(-50%, -75%); }
.sb-down::after { border-top: 4px solid #000; transform: translate(-50%, -25%); }
.sb-left::after { border-right: 4px solid #000; transform: translate(-75%, -50%); }
.sb-right::after { border-left: 4px solid #000; transform: translate(-25%, -50%); }

.docfoot { flex: none; height: 16px; margin: 0 3px 3px; display: flex; align-items: stretch; border: 1px solid #555; background: var(--plat); font: 10px/14px var(--small); }
.zoomfield { flex: none; width: 52px; padding: 0 4px; border-right: 1px solid #555; background: #fff; text-align: left; }
.docinfo { flex: none; width: 150px; padding: 0 16px 0 5px; border-right: 1px solid #555; position: relative; white-space: nowrap; overflow: hidden; }
.docinfo::after { content: ""; position: absolute; right: 5px; top: 3px; border: 4px solid transparent; border-left: 5px solid #000; border-right: 0; }
.hscroll { flex: 1; min-width: 0; }
.hscroll .sb-left, .hscroll .sb-right { height: 14px; }
.grow { flex: none; width: 15px; border-left: 1px solid #555; background: repeating-linear-gradient(135deg, transparent 0 3px, #fff 3px 4px, #888 4px 5px) var(--plat); }

/* ---------------- toolbox */
.toolbox { left: 6px; top: 8px; width: 58px; padding-bottom: 5px; z-index: 20; }
.ptitle { position: relative; height: 12px; margin: 1px 2px 0; }
.ptitle::before { content: ""; position: absolute; left: 14px; right: 2px; top: 2px; bottom: 2px; background: repeating-linear-gradient(#fdfdfd 0 1px, #9c9c9c 1px 2px); }
.pclose { position: absolute; left: 2px; top: 1px; width: 9px; height: 9px; padding: 0; border: 1px solid #333; background: linear-gradient(135deg, #a6a6a6, #f6f6f6 70%); cursor: default; }
.toolgrid { display: grid; grid-template-columns: 24px 24px; gap: 0; justify-content: center; margin: 3px 0 4px; }
.tool { width: 24px; height: 23px; padding: 0; border: 0; background: transparent; display: grid; place-items: center; position: relative; cursor: default; }
.tool svg { width: 16px; height: 16px; shape-rendering: crispEdges; }
.tool.on { background: #8e8e8e; box-shadow: inset 1px 1px #555, inset -1px -1px #c8c8c8; }
.tool.on svg { filter: invert(1); }
.tool.grp::after { content: ""; position: absolute; right: 2px; bottom: 2px; border-left: 3px solid transparent; border-bottom: 3px solid #000; }
.tool:focus-visible { outline: 1px dotted #000; outline-offset: -2px; }
.swatches { position: relative; height: 36px; margin: 6px 7px 4px; }
.sw { position: absolute; width: 22px; height: 22px; border: 1px solid #000; box-shadow: inset 0 0 0 1px #fff; }
.sw.fg { left: 2px; top: 2px; background: #000; z-index: 1; }
.sw.bg { left: 13px; top: 13px; background: #fff; }
.sw-swap { position: absolute; right: 0; top: 0; width: 8px; height: 8px; border-top: 1px solid #000; border-right: 1px solid #000; border-radius: 0 6px 0 0; }
.sw-def { position: absolute; left: 0; bottom: -1px; width: 8px; height: 8px; background: linear-gradient(135deg, #000 50%, #fff 50%); border: 1px solid #000; }
.tb-row { display: flex; justify-content: center; gap: 2px; margin-top: 3px; }
.tb-btn { width: 15px; height: 13px; border: 1px solid #555; background: linear-gradient(#fafafa, #cfcfcf); position: relative; }
.tb-btn.on { background: #a4a4a4; }
.qm::after, .qm2::after { content: ""; position: absolute; left: 3px; top: 2px; width: 7px; height: 7px; border-radius: 50%; border: 1px solid #000; }
.qm2::after { background: #000; }
.sm1::after, .sm2::after, .sm3::after { content: ""; position: absolute; inset: 2px; border: 1px solid #000; border-top-width: 2px; }
.sm3::after { background: #000; }

/* ---------------- palettes */
.palettes { position: absolute; right: 6px; top: 8px; bottom: 6px; width: 272px; display: flex; flex-direction: column; gap: 6px; z-index: 20; pointer-events: none; }
.palettes .palette { position: relative; pointer-events: auto; display: flex; flex-direction: column; min-height: 0; }
#navPal { flex: none; height: 150px; }
#histPal { flex: none; height: 186px; }
#layersPal { flex: 1 1 auto; min-height: 240px; }
.tabs { display: flex; align-items: flex-end; height: 19px; padding: 0 4px; margin-top: 2px; border-bottom: 1px solid #666; flex: none; }
.tab { position: relative; height: 17px; margin-right: -1px; padding: 0 9px; border: 1px solid #666; border-bottom: 0; border-radius: 3px 3px 0 0; background: #b9b9b9; font: 10px/16px var(--small); cursor: default; }
.tab.on { z-index: 1; height: 19px; margin-bottom: -1px; background: var(--plat); border-bottom: 1px solid var(--plat); font-weight: bold; }
.tab:focus-visible { outline: 1px dotted #000; outline-offset: -3px; }
.phone-only { display: none; }
.tabpane { display: none; }
.tabpane.on { display: flex; }
.pbody { flex: 1; min-height: 0; flex-direction: column; margin: 4px; }
.pfoot { flex: none; height: 18px; display: flex; justify-content: flex-end; align-items: center; gap: 3px; padding: 0 6px; border-top: 1px solid #999; box-shadow: inset 0 1px #fff; }
.pf-ico { width: 15px; height: 13px; position: relative; opacity: .45; }
.pf-ico::before { content: ""; position: absolute; inset: 2px 3px; border: 1px solid #000; background: #fff; }
.pf-ico.trash::before { inset: 3px 4px 1px; border-top-width: 2px; background: repeating-linear-gradient(90deg, #fff 0 1px, #777 1px 2px); }
.pf-ico.set::before { inset: 3px 2px 2px; background: #e8c86a; }
.pf-ico.mask::before { background: radial-gradient(circle, #fff 2px, #444 2.5px); }
.pf-ico.adj::before { border-radius: 50%; background: linear-gradient(90deg, #000 50%, #fff 50%); }
.pf-ico.fx::before { content: "f"; border: 0; background: none; font: italic bold 11px/9px Georgia, serif; inset: 1px 4px; }
.pf-ico.snap::before { inset: 2px 2px; background: #9a9a9a; border-radius: 1px; }

/* navigator / info */
.nav-view { flex: 1; min-height: 0; display: grid; place-items: center; background: var(--paste); border: 1px solid #777; }
.nav-box { position: relative; width: 150px; height: 84px; }
.nav-box img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.nav-box img:not([src]), .nav-box img[src=""] { visibility: hidden; }
.nav-red { position: absolute; inset: -1px; border: 2px solid #e00000; }
.nav-zoom { flex: none; display: flex; align-items: center; gap: 5px; height: 20px; padding: 0 2px; font: 10px var(--small); }
#navPct { width: 46px; border: 1px solid #777; background: #fff; padding: 0 3px; }
.nav-mtn { width: 10px; height: 8px; background: linear-gradient(135deg, transparent 45%, #333 46%) left / 50% 100% no-repeat, linear-gradient(225deg, transparent 45%, #333 46%) right / 50% 100% no-repeat; }
.nav-mtn.l { width: 14px; height: 11px; }
.nav-slider { flex: 1; height: 3px; background: #888; position: relative; box-shadow: inset 1px 1px #444; }
#navKnob { position: absolute; top: -5px; width: 8px; height: 11px; background: linear-gradient(#fff, #bbb); border: 1px solid #333; clip-path: polygon(0 0, 100% 0, 100% 60%, 50% 100%, 0 60%); }
.info-grid { display: grid; grid-template-columns: 18px 26px 1fr; row-gap: 6px; padding: 6px 8px; font: 11px/14px var(--small); background: #fff; border: 1px solid #777; flex: 1; align-content: start; }
.ig-i { font-size: 12px; }

/* history */
.hist-list, .layer-list, .chan-list, .paths-list, .actions-list { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; background: #f2f2f2; border: 1px solid #777; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.hrow { display: flex; align-items: center; gap: 5px; width: 100%; height: 20px; padding: 0 6px 0 0; border: 0; border-bottom: 1px solid #d0d0d0; background: none; text-align: left; font: 11px/19px var(--small); white-space: nowrap; cursor: default; }
.hrow .hb { flex: none; width: 18px; height: 19px; border-right: 1px solid #c2c2c2; display: grid; place-items: center; }
.hrow .hi { flex: none; width: 16px; height: 16px; display: grid; place-items: center; }
.hrow .hi svg { width: 14px; height: 14px; }
.hrow .ht { overflow: hidden; text-overflow: ellipsis; }
.hrow.cur { background: var(--sel); }
.hrow.future { color: #9a9a9a; }
.hrow.future .hi { opacity: .4; }
.hrow.snap { height: 34px; }
.hrow.snap .hb { height: 33px; }
.hrow .hthumb { flex: none; width: 44px; height: 25px; border: 1px solid #777; position: relative; }
.hrow .hthumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.hb-brush { width: 12px; height: 12px; }
.hrow:focus-visible, .lrow:focus-visible, .lbody:focus-visible { outline: 1px dotted #000; outline-offset: -2px; }
.arow { display: flex; align-items: center; gap: 5px; height: 20px; padding: 0 6px; border-bottom: 1px solid #d0d0d0; font: 11px/19px var(--small); }
.arow .chk { width: 14px; border-right: 1px solid #c2c2c2; }

/* layers */
.lp-top { position: relative; flex: none; display: flex; align-items: center; gap: 5px; height: 26px; padding: 0 2px; }
.popup { position: relative; flex: none; }
.popup select { appearance: none; -webkit-appearance: none; width: 104px; height: 19px; padding: 0 18px 0 6px; border: 1px solid #333; border-radius: 3px; background: linear-gradient(#fff, #d6d6d6); box-shadow: 1px 1px 0 #888; font: 11px/17px var(--small); color: #000; cursor: default; }
.popup::before, .popup::after { content: ""; position: absolute; right: 5px; width: 0; height: 0; border: 3.5px solid transparent; pointer-events: none; }
.popup::before { top: 4px; border-bottom: 4px solid #000; border-top: 0; }
.popup::after { bottom: 4px; border-top: 4px solid #000; border-bottom: 0; }
.op-label { margin-left: 4px; }
.op-field { display: flex; align-items: stretch; height: 19px; }
.op-field input { width: 42px; height: 19px; border: 1px solid #555; box-shadow: inset 1px 1px #aaa; padding: 0 3px; font: 11px var(--small); background: #fff; color: #000; border-radius: 0; }
.op-btn { width: 14px; padding: 0; border: 1px solid #555; border-left: 0; background: linear-gradient(#fff, #cfcfcf); position: relative; cursor: default; }
.op-btn::after { content: ""; position: absolute; left: 4px; top: 5px; border: 3.5px solid transparent; border-left: 5px solid #000; border-right: 0; }
.op-pop { position: absolute; right: 0; top: 24px; z-index: 5; width: 150px; padding: 8px 10px; background: var(--plat); border: 1px solid #222; box-shadow: 2px 2px 0 rgba(0,0,0,.35); }
.op-pop input { width: 100%; margin: 0; accent-color: #555; }
.lp-lock { flex: none; display: flex; align-items: center; gap: 4px; height: 20px; padding: 0 4px 2px; font: 11px var(--small); border-bottom: 1px solid #999; margin-bottom: 4px; }
.lk { width: 22px; height: 15px; display: inline-flex; align-items: center; gap: 1px; position: relative; padding-left: 12px; }
.lk::before { content: ""; position: absolute; left: 0; top: 2px; width: 9px; height: 9px; border: 1px solid #777; background: #fff; }
.lk.on::before { content: "\2713"; font: bold 9px/9px var(--small); color: #777; text-align: center; }
.lk i { display: block; width: 10px; height: 10px; opacity: .55; }
.lk-tr { background: conic-gradient(#888 25%, #fff 0 50%, #888 0 75%, #fff 0) 0 0 / 5px 5px; border: 1px solid #555; }
.lk-br { background: linear-gradient(135deg, transparent 40%, #000 40% 60%, transparent 60%); }
.lk-mv { background: linear-gradient(#000, #000) center / 1px 100% no-repeat, linear-gradient(#000, #000) center / 100% 1px no-repeat; }
.lk-all { border: 1px solid #000; border-radius: 4px 4px 0 0; border-bottom: 0; height: 5px !important; margin-top: -3px; box-shadow: 0 5px 0 0 #000; }

.layer-list { background: #e6e6e6; }
.lrow { display: flex; align-items: stretch; height: 38px; border-bottom: 1px solid #a8a8a8; background: var(--plat); }
.lrow.folder { height: 22px; }
.lrow .eye { flex: none; width: 24px; padding: 0; border: 0; border-right: 1px solid #a8a8a8; background: var(--plat); display: grid; place-items: center; cursor: default; box-shadow: inset 1px 1px #fff, inset -1px -1px #b0b0b0; }
.lrow .eye svg { width: 14px; height: 10px; visibility: hidden; }
.lrow .eye[aria-pressed="true"] svg { visibility: visible; }
.lrow.dim .eye svg { opacity: .35; }
.lrow .brushcol { flex: none; width: 19px; border-right: 1px solid #a8a8a8; display: grid; place-items: center; box-shadow: inset 1px 1px #fff; }
.lrow .brushcol svg { width: 12px; height: 12px; visibility: hidden; }
.lrow.sel .brushcol svg { visibility: visible; }
.lbody { flex: 1; min-width: 0; display: flex; align-items: center; gap: 7px; padding: 0 6px 0 4px; border: 0; background: none; text-align: left; font: 11px/14px var(--small); cursor: default; -webkit-tap-highlight-color: transparent; touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.lrow.inset .lbody { padding-left: 18px; }
.lrow.sel .lbody { background: var(--sel); }
.lthumb { flex: none; position: relative; width: 54px; height: 31px; border: 1px solid #6a6a6a; }
.lthumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: 0; transition: opacity .25s; }
.lthumb img.ok { opacity: 1; }
.lthumb .so { position: absolute; right: -1px; bottom: -1px; width: 9px; height: 9px; background: #fff; border: 1px solid #333; }
.lthumb .so::after { content: ""; position: absolute; left: 1px; top: 1px; width: 3px; height: 3px; border: 1px solid #333; border-width: 0 1px 1px 0; }
.lname { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lrow.folder .lname { font-weight: bold; }
.llock { flex: none; width: 9px; height: 11px; position: relative; opacity: .7; }
.llock::before { content: ""; position: absolute; left: 1px; top: 0; width: 5px; height: 5px; border: 1.5px solid #000; border-bottom: 0; border-radius: 3px 3px 0 0; }
.llock::after { content: ""; position: absolute; left: 0; bottom: 0; width: 9px; height: 6px; background: #000; }
.tri { flex: none; width: 10px; padding: 0; border: 0; background: none; font-size: 9px; line-height: 1; cursor: default; }
.folder-ico { flex: none; width: 16px; height: 12px; position: relative; background: #e2c46a; border: 1px solid #6b5418; border-radius: 0 1px 1px 1px; }
.folder-ico::before { content: ""; position: absolute; left: -1px; top: -4px; width: 7px; height: 3px; background: #e2c46a; border: 1px solid #6b5418; border-bottom: 0; border-radius: 1px 2px 0 0; }

.crow { display: flex; align-items: center; height: 38px; border-bottom: 1px solid #a8a8a8; background: var(--sel); font: 11px var(--small); }
.crow .eye { width: 24px; height: 100%; display: grid; place-items: center; border-right: 1px solid #a8a8a8; background: var(--plat); }
.crow .eye svg { width: 14px; height: 10px; }
.crow canvas { width: 54px; height: 31px; margin: 0 7px 0 23px; border: 1px solid #6a6a6a; background: #fff; }
.crow .k { margin-left: auto; padding-right: 8px; }

/* ---------------- case study: the layer's own document */
.cswin { z-index: 15; }
.cs-scroll { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; margin: 0 3px; border: 1px solid #555; border-bottom: 0; background: var(--paste); overscroll-behavior: contain; -webkit-overflow-scrolling: touch; outline: 0; }
.cs-page { max-width: 1000px; margin: 22px auto 30px; padding: 30px 34px 36px; background: #fff; box-shadow: 0 0 0 1px #4a4a4a, 3px 3px 0 rgba(0,0,0,.18); font: 15px/1.5 "Helvetica Neue", Helvetica, Arial, sans-serif; color: #111;
  --ab-fg: #111; --ab-muted: #555; --ab-accent: #333399; --ab-gap: 16px; --ab-chrome: 150px; }
.cs-page .ab-title { font-weight: bold; font-size: 34px; line-height: 1.1; letter-spacing: -.02em; }
.cs-page .ab-client { margin-top: -14px; font-weight: bold; font-size: 11px; letter-spacing: .1em; color: #666; }
.cs-page .ab-lede { font-size: 17px; line-height: 1.45; max-width: 60ch; }
.cs-page .ab-heading { font-weight: bold; font-size: 15px; padding-top: 12px; border-top: 1px solid #111; }
.cs-page .ab-text { max-width: 70ch; color: #222; }
.cs-page .ab-credits { white-space: pre-line; border-top: 1px solid #ccc; padding-top: 12px; }
.cs-page .ab-audio audio { max-width: 520px; }
.cs-foot .docinfo { width: auto; flex: 1; }

/* ---------------- dialogs */
.modal { position: fixed; inset: 0; z-index: 80; display: grid; justify-items: center; align-items: start; padding-top: 18vh; }
.dlg { width: min(420px, calc(100vw - 24px)); background: var(--plat); border: 1px solid #000; padding: 3px; box-shadow: 2px 2px 0 rgba(0,0,0,.4); }
.dlg-in { border: 1px solid #fff; border-right-color: #888; border-bottom-color: #888; padding: 14px 14px 12px; }
.dlg-row { display: flex; gap: 14px; align-items: flex-start; }
.dlg-ico { flex: none; width: 32px; height: 32px; }
.dlg-msg { font: 600 12px/1.4 var(--ui); padding-top: 2px; }
.dlg-msg p { margin: 0 0 6px; }
.dlg-btns { display: flex; gap: 12px; margin-top: 18px; align-items: center; }
.dlg-btns .grow-gap { flex: 1; }
.btn { min-width: 70px; height: 20px; padding: 0 12px; border: 1px solid #222; border-radius: 4px; background: linear-gradient(#ffffff, #cfcfcf); box-shadow: inset 1px 1px #fff; font: 600 12px/18px var(--ui); cursor: default; }
.btn:active { background: linear-gradient(#6d6d6d, #9a9a9a); color: #fff; }
.btn.def { box-shadow: 0 0 0 2px var(--plat), 0 0 0 4px #222, inset 1px 1px #fff; border-radius: 5px; margin: 0 3px; }
.btn:focus-visible { outline: 1px dotted #000; outline-offset: 2px; }
.dlg.mov { width: min(500px, calc(100vw - 16px)); padding: 0; }
.dlg.mov .wtitle-text { max-width: none; }
.dlg.mov .dlg-in { margin: 0 3px 3px; border: 1px solid #888; border-right-color: #fff; border-bottom-color: #fff; }
.fi-sec { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; font: 600 12px var(--ui); }
.fi-sec .popup select { width: 170px; }
.fi-grid { display: grid; grid-template-columns: 120px 1fr; gap: 8px 10px; align-items: start; font: 11px/1.35 var(--small); }
.fi-grid label { text-align: right; padding-top: 3px; font: 600 11px/1.3 var(--ui); }
.fi-val { min-height: 20px; padding: 2px 5px; border: 1px solid #666; box-shadow: inset 1px 1px #aaa; background: #fff; overflow-wrap: anywhere; }
.fi-val.tall { min-height: 74px; }
.fi-val a { color: #1a1aa6; }
.fi-list { margin: 0; padding: 0; list-style: none; }
.fi-list li { padding: 1px 0; }
.saving .bar { height: 11px; margin-top: 10px; border: 1px solid #222; background: #fff; }
.saving .bar span { display: block; height: 100%; width: 0; background: repeating-linear-gradient(90deg, #6a6aa8 0 6px, #8d8dc6 6px 10px); transition: width .45s linear; }

/* ---------------- splash */
.splash-wrap { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; background: var(--desk); transition: opacity .35s; }
.splash-wrap.gone { opacity: 0; pointer-events: none; }
.splash { width: min(540px, 100%); display: grid; grid-template-columns: 200px 1fr; background: #f3f1ec; border: 1px solid #000; box-shadow: 3px 3px 0 rgba(0,0,0,.35); }
.splash-art { position: relative; height: 250px; background: linear-gradient(160deg, #20283d, #3b4a72); overflow: hidden; }
.sl { position: absolute; left: 34px; width: 120px; height: 72px; border: 1px solid rgba(255,255,255,.75); transform: skewY(-14deg); box-shadow: 0 0 0 1px rgba(0,0,0,.25); }
.s1 { top: 150px; background: conic-gradient(#d0d0d0 25%, #fff 0 50%, #d0d0d0 0 75%, #fff 0) 0 0 / 12px 12px; }
.s2 { top: 124px; left: 40px; background: rgba(214, 84, 54, .82); }
.s3 { top: 98px; left: 46px; background: rgba(236, 186, 64, .82); }
.s4 { top: 72px; left: 52px; background: rgba(78, 152, 196, .82); }
.s5 { top: 46px; left: 58px; background: rgba(255, 255, 255, .22); border-style: dashed; }
.splash-text { padding: 26px 24px 20px; display: flex; flex-direction: column; font: 11px/1.4 var(--small); }
.splash-lic { color: #555; }
.splash-name { font: bold 20px/1.2 var(--ui); margin-top: 2px; }
.splash-status { margin-top: auto; color: #333; min-height: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.splash-bar { height: 4px; margin-top: 6px; background: #d8d4cc; }
.splash-bar span { display: block; height: 100%; width: 0; background: #3b4a72; transition: width .2s; }

/* ---------------- phone: canvas on top, Layers palette as a bottom sheet */
@media (max-width: 760px) {
  :root { --menubar: 22px; }
  .menubar { font-size: 11.5px; line-height: 21px; }
  .menus { padding-left: 4px; }
  .mtitle { padding: 0 5.5px; }
  .menubar-right { padding-right: 6px; }
  .mb-clock, .mb-user { display: none; }
  .toolbox, #navPal, #histPal { display: none !important; }
  .workspace { display: flex; flex-direction: column; }
  #doc { position: relative; left: auto !important; top: auto !important; width: auto !important; height: auto !important; flex: none; margin: 4px 4px 0; }
  .docbody { grid-template-columns: 14px minmax(0, 1fr) 0; grid-template-rows: 14px auto; }
  .vscroll { display: none; }
  .stage { height: calc((100vw - 32px) * .5625 + 10px); }
  .docfoot .hscroll { display: none; }
  .docinfo { flex: 1; width: auto; }
  .palettes { position: relative; inset: auto; width: auto; flex: 1; min-height: 0; margin: 6px 4px 0; display: flex; }
  #layersPal { flex: 1; min-height: 0; border-bottom: 0; padding-bottom: env(safe-area-inset-bottom); }
  .phone-only { display: block; }
  .tab { padding: 0 12px; font-size: 11px; height: 22px; line-height: 21px; }
  .tab.on { height: 24px; }
  .tabs { height: 24px; }
  .lrow { height: 46px; }
  .lrow.folder { height: 32px; }
  .lrow .eye { width: 34px; }
  .lrow .eye svg { width: 16px; height: 11px; }
  .lrow .brushcol { width: 16px; }
  .lthumb { width: 64px; height: 36px; }
  .lbody { font-size: 13px; }
  .lrow.inset .lbody { padding-left: 12px; }
  .lp-top { height: 32px; }
  .popup select, .op-field input { height: 24px; font-size: 12px; }
  .op-field { height: 24px; }
  .op-btn { width: 20px; }
  .hrow { height: 30px; font-size: 13px; }
  .tri { width: 22px; font-size: 11px; }
  .cswin { position: fixed; left: 0 !important; top: var(--menubar) !important; width: 100% !important; height: auto !important; bottom: 0; z-index: 30 !important; border-left: 0; border-right: 0; }
  #doc .wclose { display: none; }
  .cswin .wtitle { height: 30px; }
  .cswin .wtitle::before { top: 6px; bottom: 6px; }
  .cswin .wclose { top: 8px; left: 10px; width: 15px; height: 14px; }
  .cswin .wtitle-text { line-height: 30px; font-size: 12px; max-width: calc(100% - 100px); }
  .cs-scroll { margin: 0; border-left: 0; border-right: 0; }
  .cs-page { margin: 10px 8px 20px; padding: 18px 14px 24px; --ab-chrome: 110px; }
  .cs-page .ab-title { font-size: 23px; }
  .cs-foot { display: none; }
  .modal { padding-top: 22vh; }
  .splash { grid-template-columns: 1fr; }
  .splash-art { height: 150px; }
  .sl { left: 50%; margin-left: -60px; width: 120px; height: 56px; }
  .s1 { top: 84px; } .s2 { top: 66px; margin-left: -54px; } .s3 { top: 48px; margin-left: -48px; } .s4 { top: 30px; margin-left: -42px; } .s5 { top: 12px; margin-left: -36px; }
}
@media (min-width: 761px) and (max-height: 760px) { #navPal { display: none; } #histPal { height: 150px; } }
@media (prefers-reduced-motion: reduce) { .ants .a2 { animation: none; } .splash-wrap { transition: none; } }
