/* The page around a pro app (craft-host.js): the suite's bar on top, the app filling the rest. */
html, body { height: 100%; }
.shell { height: 100vh; height: 100dvh; display: flex; flex-direction: column; }
#root { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.cr-stage { position: relative; flex: 1; min-height: 0; background: #262626; }
.cr-stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.cr-missing { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 24px; text-align: center; background: var(--paper); }
.cr-missing h2 { font-size: 22px; }
.cr-status { font-size: 13px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40vw; }
.cr-open { display: flex; flex-direction: column; gap: 10px; }
.cr-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 8px; max-height: 50vh; overflow-y: auto; }
.cr-list p { margin: 0; }
.cr-file { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); text-align: left; cursor: pointer; min-width: 0; }
.cr-file:hover { background: var(--hover); }
.cr-file span { display: flex; flex-direction: column; min-width: 0; }
.cr-file b, .cr-file small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cr-file b { font-weight: 600; font-size: 14px; }
.cr-file small { font-size: 12.5px; }
@media (max-width: 700px) { .cr-status { display: none; } }
/* a Pro app opened in a browser: it runs in the desktop app */
.cr-desk { flex: 1; display: grid; place-items: center; padding: 24px 16px; background: var(--paper); }
.cr-desk-card { max-width: 560px; display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.cr-desk-card h1 { font-size: clamp(24px, 3vw, 32px); }
.cr-desk-card p { margin: 0; color: var(--text-2); line-height: 1.6; }
.cr-desk-card p.muted { color: var(--text-3); font-size: 14px; }
.cr-desk-btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }
/* a Pro app in the browser: a slim note about the desktop app */
.cr-webbar { display: flex; align-items: center; gap: 10px; padding: 6px 12px; background: var(--surface-2); border-bottom: 1px solid var(--line); font-size: 13px; color: var(--text-2); }
.cr-webbar span { flex: 1; min-width: 0; }
.cr-webbar .tb { width: 28px; height: 28px; border: 0; background: none; color: var(--text-3); cursor: pointer; border-radius: 6px; }

/* Files: your Standard Cloud files beside the app */
.cr-panel { position: fixed; top: 56px; right: 0; bottom: 0; width: min(340px, 100vw); z-index: 30; background: var(--surface); border-left: 1px solid var(--line); box-shadow: -12px 0 32px rgba(0,0,0,.18); display: flex; flex-direction: column; gap: 10px; padding: 12px 12px 10px; }
.cr-ph { display: flex; align-items: center; justify-content: space-between; font-size: 15px; }
.cr-ph .tb { width: 32px; height: 32px; border: 0; border-radius: 8px; background: none; color: var(--text-2); font-size: 20px; cursor: pointer; }
.cr-ph .tb:hover { background: var(--hover); }
.cr-plist { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 2px; margin: 0 -4px; }
.cr-plist .cr-file { width: 100%; }
.cr-plist .cr-file[aria-current="true"] { background: var(--tint); }
.cr-plist p { padding: 8px 4px; margin: 0; }
.cr-pall { font-size: 13.5px; text-align: center; padding: 6px; }
