.brand{background:none;padding:0;border:0}.brand-icon{width:40px;height:40px;flex:none}
.ui-hidden .topbar,.ui-hidden .studio-global-header,.ui-hidden .sidebar,.ui-hidden .view-label,.ui-hidden .canvas-bottom,.ui-hidden .empty-state,.ui-hidden .selection-bar{display:none!important}
body.ui-hidden{padding-top:0!important}.ui-hidden .workspace{height:100dvh!important}.ui-hidden .canvas{background-image:none!important}
.sidebar-collapsed .view-label:before{content:none}
#start-dialog{width:520px;padding:30px;max-height:calc(100dvh - 40px);overflow:auto;scrollbar-width:thin;scrollbar-color:#4d425e #23242a}#start-dialog::backdrop{background:#18191fe8;backdrop-filter:blur(6px)}
.start-icon{display:block;width:62px;height:62px;margin:0 0 17px}#start-dialog .eyebrow{font-size:10px;color:#aaa0be;letter-spacing:1.5px}
#start-dialog h2{font-size:29px;margin:12px 0}#start-dialog p{margin:0 0 25px;line-height:1.65}
#project-form{display:flex;flex-direction:column;gap:11px}#project-form label{font-size:13px;color:#d4cedf}#project-name{width:100%;background:#18191e;color:#f0eafe;border:1px solid #48424f;border-radius:8px;padding:13px;font-size:14px;outline:none}#project-name:focus{border-color:#c3b2ff}#project-name::placeholder{color:#88808f}
#project-form .btn,#quick-board{width:100%;font-size:14px;padding:13px}#quick-board{margin-top:10px}#start-import{display:flex;align-items:center;justify-content:center;gap:8px;width:100%;margin:15px 0 0;text-decoration:none;padding:5px}
#recent-projects{margin-top:23px;padding-top:17px;border-top:1px solid #3b3543}#recent-projects h3{font-size:13px;font-weight:500;color:#bcb1ce;margin:0 0 10px}#project-list{display:flex;flex-direction:column;gap:7px;max-height:210px;overflow:auto}
.recent-project{display:flex;flex-direction:column;gap:4px;text-align:left;width:100%;padding:12px 14px;border-radius:8px;background:#2d2835}.recent-project:hover{background:#3a3147}.recent-project strong{font-size:14px;font-weight:500;color:#e5ddef;overflow-wrap:anywhere}.recent-project span{font-size:12px;color:#a79ab9}
#start-dialog .start-storage{font-size:12px;color:#948b9f;margin:22px 0 0}
@media(max-width:1100px){.topbar{gap:12px}.topbar .board-heading input{width:160px}.topbar .header-divider,.topbar .save-status{display:none}.topbar .btn{font-size:12px;padding:10px}.brand{font-size:26px}}
@media(max-width:750px){.topbar .board-heading{display:none}.header-actions{gap:6px}.topbar .brand{font-size:0;gap:0}.topbar .brand-dot{display:none}.topbar .btn{font-size:0;gap:0}.topbar .btn svg{width:19px;height:19px}.topbar .header-actions{margin-left:auto}}
@media(max-width:450px){#start-dialog{padding:25px}.start-icon{width:58px;height:58px;margin-bottom:16px}#start-dialog h2{font-size:25px}.selection-bar{max-width:calc(100vw - 25px);gap:6px}.selection-bar .note-colors{gap:4px}}

.ui-hidden .canvas-top{left:90px;right:26px;justify-content:flex-end}.tool-rail{max-height:calc(100dvh - 90px);overflow:auto;scrollbar-width:thin}
.item.text{background:transparent;box-shadow:none;display:flex;padding:12px;color:#e8e4ef}.item.text .note-text{font-size:24px;line-height:1.4}
.context-menu{position:fixed;z-index:60;width:290px;max-width:calc(100vw - 16px);max-height:calc(100dvh - 16px);overflow:auto;padding:7px;border:1px solid #45414c;border-radius:12px;background:#242329;box-shadow:0 16px 60px #0008;scrollbar-width:thin}
.context-menu button{display:flex;align-items:center;gap:10px;width:100%;padding:9px 10px;border-radius:6px;text-align:left;background:transparent;font-size:13px;color:#e4dfed}.context-menu button:hover,.context-menu button:focus-visible{background:#42374f;outline:none}.context-menu button:disabled{opacity:.35}.context-menu .icon{width:17px;height:17px;flex:none}.context-menu kbd{margin-left:auto;font:10px Manrope,sans-serif;white-space:nowrap;color:#a69bb8;background:none;border:0;padding:0}.context-divider{height:1px;background:#3b3742;margin:5px 4px}
.close-project-actions{display:flex;flex-direction:column;gap:10px}.close-project-actions .btn{justify-content:center}.close-project-actions .text-btn{padding:10px}
@media(max-width:750px){.ui-hidden .canvas-top{right:12px;left:75px;top:12px}.ui-hidden .collage-btn{padding:10px;font-size:12px}}

#start-dialog.is-studio-library> :not(#refes-studio-library):not(#close-start){display:none!important}
#start-dialog:not(.is-studio-library)>#refes-studio-library{display:none}
#start-dialog.is-studio-library{width:min(1120px,94vw);max-width:94vw;max-height:90dvh;overflow:auto;text-align:left}
#refes-studio-library{width:100%;padding:12px 0}#refes-studio-library>.btn{margin:14px 10px 0 0}#refes-studio-library h2{overflow-wrap:anywhere}#refes-studio-library .gbp-heading h1{font-size:28px}

/* Text formatting stays available in the clean canvas view. */
.text-format-bar{position:absolute;top:125px;left:50%;transform:translateX(-50%);z-index:7;display:flex;align-items:end;flex-wrap:wrap;gap:9px;width:max-content;max-width:calc(100% - 110px);padding:12px;background:#1b1c20;border:1px solid #45424e;border-radius:12px;box-shadow:0 8px 30px #0004}
.ui-hidden .text-format-bar{top:76px}.text-format-bar label{display:flex;flex-direction:column;gap:5px;color:#a9a2b6;font-size:10px}.text-format-bar select,.text-format-bar input{height:32px;background:#2c2933;border:1px solid #48414f;border-radius:5px;color:#eee8f8;font:12px 'DM Sans',sans-serif;padding:4px 6px}.text-format-bar select{max-width:140px}.text-format-bar input[type=number]{width:66px}.text-format-bar input[type=color]{width:36px;padding:3px;cursor:pointer}.text-format-toggles{display:flex;gap:3px}.text-format-toggles button{width:31px;height:32px;border-radius:5px;background:#2c2933;color:#eee8f8;font:16px Georgia,serif}.text-format-toggles button[aria-pressed=true]{background:var(--accent);color:#24202f}.text-format-bar :focus-visible{outline:2px solid var(--accent);outline-offset:2px}.note-text{font-synthesis:weight style}
.item.image .media-visual{height:100%;border-radius:7px}.item.image .media-visual img{object-fit:fill}
.item .resize-handle{right:auto;bottom:auto;background:transparent;border:0;border-radius:0;z-index:4}
.resize-handle:after{content:'';position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:10px;height:10px;border:2px solid #24252a;border-radius:3px;background:var(--accent);pointer-events:none}
.resize-handle[data-direction=n],.resize-handle[data-direction=s]{left:8px;width:calc(100% - 16px);height:14px;cursor:ns-resize}.resize-handle[data-direction=n]{top:-9px}.resize-handle[data-direction=s]{bottom:-9px}
.resize-handle[data-direction=w],.resize-handle[data-direction=e]{top:8px;height:calc(100% - 16px);width:14px;cursor:ew-resize}.resize-handle[data-direction=w]{left:-9px}.resize-handle[data-direction=e]{right:-9px}
.resize-handle[data-direction=nw],.resize-handle[data-direction=ne],.resize-handle[data-direction=sw],.resize-handle[data-direction=se]{width:18px;height:18px;z-index:5}
.resize-handle[data-direction=nw]{left:-11px;top:-11px;cursor:nwse-resize}.resize-handle[data-direction=ne]{right:-11px;top:-11px;cursor:nesw-resize}.resize-handle[data-direction=sw]{left:-11px;bottom:-11px;cursor:nesw-resize}.resize-handle[data-direction=se]{right:-11px;bottom:-11px;cursor:nwse-resize}
@media(max-width:750px){.text-format-bar{left:76px;transform:none;max-width:calc(100% - 88px);gap:6px;padding:8px}.text-format-bar select{max-width:120px}}

/* Coordinates are calculated next to the selected text, avoiding board items. */
#text-format-bar{transform:none;right:auto;bottom:auto;max-height:calc(100dvh - 30px);overflow:auto}#text-format-bar.is-docked{position:fixed;max-width:calc(100vw - 24px)}
.workspace{background:#24252a}

#start-dialog.is-project-loading #refes-studio-library> :not(.refes-project-progress){display:none!important}.refes-project-progress{min-height:140px;display:flex;align-items:center;justify-content:center;gap:14px;margin:0!important;color:#d9d1e8!important}.refes-project-progress:before{content:'';width:20px;height:20px;border:2px solid #51465f;border-top-color:#c3b2ff;border-radius:50%;animation:refes-loading 1s linear infinite}@keyframes refes-loading{to{transform:rotate(360deg)}}

#text-format-bar{max-width:min(440px,calc(100% - 100px))}

.note-text{scrollbar-width:none}.note-text::-webkit-scrollbar{display:none;width:0;height:0}

/* Free text keeps its chosen width and grows/shrinks to its natural height. */
.item.text{display:block}.item.text .note-text{height:auto;min-height:0;overflow:visible}

#items{isolation:isolate}.item.frame,.item.frame.selected{z-index:-1;pointer-events:none;border:1px solid #ffffff38;border-radius:12px;box-shadow:none}.item.frame .frame-title{position:absolute;left:0;top:-32px;min-width:120px;max-width:100%;padding:6px 10px;font-size:13px;color:#e2dcec;background:#302d38;border-radius:6px;pointer-events:auto;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.frame-edge{position:absolute;pointer-events:auto}.frame-edge-n,.frame-edge-s{height:12px;left:0;right:0}.frame-edge-n{top:-5px}.frame-edge-s{bottom:-5px}.frame-edge-e,.frame-edge-w{width:12px;top:0;bottom:0}.frame-edge-e{right:-5px}.frame-edge-w{left:-5px}.item.frame .resize-handle{pointer-events:auto}.item.frame.locked{cursor:default}.item.frame.locked .resize-handle{display:none!important}.frame-bar input:not([type=color]){width:145px}.frame-bar .btn{height:32px;padding:6px 9px;font-size:12px}.frame-bar{transform:none;max-width:min(510px,calc(100% - 100px))}.tool-frame{cursor:crosshair}

.item.frame,.item.frame.selected{background:transparent!important}

#frame-bar.is-docked{position:fixed;max-width:calc(100vw - 24px)}

.refes-readonly [data-tool]:not([data-tool="hand"]),.refes-readonly #collage,.refes-readonly #undo,.refes-readonly #redo,.refes-readonly #delete,.refes-readonly #duplicate,.refes-readonly .item-actions,.refes-readonly #text-format-bar {display:none!important}
