/* PicPlayer chrome shared with DrawDomain. Editor styling stays in styles.css. */
.hidden { display: none !important; }
.app-bar { width: 100%; min-width: 0; padding-right: 9px; background: #10141b; border-bottom: 1px solid #252b35; }
.app-bar .brand { flex: 0 0 174px; }
.menu-bar, .menu-popovers, .document-tabs, .profile-button {
  --accent: #4db8ff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 12px;
}
.menu-popovers { color: #edf1f7; }
/* Tabs are a workspace strip, not a third full-width header row. */
.document-area {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}
.document-tabs {
  display: flex;
  align-items: stretch;
  flex: 0 0 32px;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  background: #171b22;
  border-bottom: 1px solid #303640;
  scrollbar-width: none;
}
.document-tabs:empty { display: none; }
.document-tabs::-webkit-scrollbar { display: none; }
.document-tab {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 9px;
  min-width: 130px;
  max-width: 230px;
  padding: 0 12px;
  border: 0;
  border-right: 1px solid #272d37;
  background: #151922;
  color: #9aa4b4;
  cursor: pointer;
}
.document-tab.active { background: #222833; color: #fff; border-top: 2px solid var(--accent); }
.document-tab span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.document-tab .dirty { flex: 0 0 6px; width: 6px; height: 6px; border-radius: 50%; background: #9ea8b8; }
.document-tab .close { flex: 0 0 auto; margin-left: auto; border: 0; background: transparent; color: #788397; padding: 2px; cursor: pointer; }
.document-tab:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.profile-button{display:grid;place-items:center;flex:0 0 30px;width:30px;height:30px;border:1px solid #414c5f;border-radius:50%;background:#202938;color:#cfdbeb;cursor:pointer;padding:0;transition:background .15s,border-color .15s}
.profile-button:hover,.profile-button.active{background:#33435a;border-color:#6e9bc7}
.profile-button.is-signed-in{border-color:#469b81;background:#153b32;color:#a1eed5}
.profile-initials{font-size:13px;font-weight:750;line-height:1}
.menu-bar{display:flex;align-items:center;flex:0 1 auto;min-width:0;white-space:nowrap;overflow-x:auto;overflow-y:hidden;scrollbar-width:none}
.menu-bar::-webkit-scrollbar{display:none}
.application-menu{padding:0 4px}
.network-menu{margin-left:auto;padding-left:16px}
.menu-bar>button{flex:0 0 auto;height:30px;border-radius:5px;border:0;background:transparent;padding:0 8px;cursor:pointer;color:#d4d9e1;white-space:nowrap}
.menu-bar>button:hover,.menu-bar>button.active{background:#2a313d}
.menu-bar>button:focus-visible,.profile-button:focus-visible{outline:2px solid var(--accent);outline-offset:-2px}
.menu-popovers{position:fixed;inset:0;pointer-events:none;z-index:100}
.menu-popover{display:none;position:absolute;top:calc(var(--titlebar-height) + 3px);min-width:min(245px,calc(100vw - 16px));max-width:calc(100vw - 16px);padding:5px;background:#252b35;border:1px solid #3a424f;border-radius:7px;box-shadow:0 18px 50px #000b;pointer-events:auto;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#566274 #252b35}
.menu-popover.open{display:block}
.menu-popover button,.menu-popover a{display:flex;align-items:center;justify-content:space-between;gap:24px;width:100%;border:0;background:transparent;padding:7px 9px;border-radius:4px;text-align:left;cursor:pointer;color:inherit;text-decoration:none;white-space:nowrap;line-height:1.35}
.menu-popover button:hover,.menu-popover a:hover,.menu-popover button:focus-visible,.menu-popover a:focus-visible{background:#3a4656;outline:none}
.menu-popover button:focus-visible,.menu-popover a:focus-visible{box-shadow:inset 0 0 0 1px #80b7e3}
.menu-popover button[data-planned=true]{color:#7e8795}
.menu-popover kbd{color:#8994a5;font-family:inherit;font-size:10px}
.menu-separator{height:1px;background:#46505f;margin:5px 5px}
.network-popover{min-width:min(215px,calc(100vw - 16px))}
.current-app-badge{font-size:9px;color:#86c8f7;font-weight:500}
.profile-popover{width:245px}
.profile-summary{display:grid;gap:5px;padding:8px 9px 9px;overflow-wrap:anywhere}
.profile-summary strong{font-size:13px;font-weight:650}
.profile-summary>span{font-size:11px;color:#a0adbf}
.profile-popover .profile-join{color:#90ceff}
.profile-popover .profile-legal-link{font-size:11px;color:#adb9ca}

/* Keep row two full-width: only tool controls scroll; the account icon never does. */
.context-bar { gap: 12px; padding: 0 9px; background: #1b2029; border-bottom: 1px solid #303640; }
.tool-controls { display: flex; align-items: center; flex: 1; gap: 6px; min-width: 0; height: 100%; overflow-x: auto; overflow-y: hidden; white-space: nowrap; scrollbar-width: none; }
.tool-controls::-webkit-scrollbar { display: none; }
.tool-controls > * { flex-shrink: 0; }
.document-area > .workspace { flex: 1; }
.document-tab .dirty[hidden] { display: none; }
.document-tab .close:hover, .document-tab .close:focus-visible { color: #fff; outline: 1px solid #4db8ff; border-radius: 3px; }
.menu-popover button:disabled { opacity: .35; cursor: default; }
.menu-popover .menu-check { margin-left: auto; }
.document-name-field { padding: 12px 14px; }
.autosave-status { font-size: 10px; color: #798397; white-space: nowrap; }
.save-dot { flex: 0 0 6px; }
#status-zoom { min-width: 34px; text-align: right; }
.app-shell.no-document .inspector { opacity: .45; }
.app-shell.no-document .ruler { visibility: hidden; }
.app-shell.no-document #empty-hint { pointer-events: auto; }
@media (max-width: 1280px) {
  .menu-bar > button { padding: 0 6px; font-size: 11px; }
  .network-menu { padding-left: 10px; }
}
@media (max-width: 1020px) { .autosave-status { display: none; } }
@media (max-width: 760px) {
  .app-bar { padding-right: 5px; }
  .app-bar .brand { flex-basis: 150px; padding: 0 10px; gap: 8px; }
  .app-bar .brand-copy { display: flex; }
  .app-bar .brand-copy small { display: block; }
  .menu-bar > button { padding: 0 7px; }
  .network-menu { padding-left: 7px; }
  .context-bar, .tool-controls { gap: 8px; }
  .profile-button { width: 29px; height: 29px; flex-basis: 29px; }
}
@media (max-width: 400px) {
  .app-bar .brand { flex-basis: 120px; padding: 0 7px; gap: 6px; }
  .app-bar .brand-copy strong { font-size: 11px; }
}

/* Keep the empty-document controls usable inside a narrow canvas column. */
.empty-hint { width: min(380px, calc(100% - 32px)); }
@media (max-width: 600px) {
  .empty-hint { padding: 20px 14px; }
  .empty-hint > div:last-child { flex-wrap: wrap; }
}
