/* Motion values from React Bits src/css/variables.css and docs.css. */
:root{--ease-out:cubic-bezier(.23,1,.32,1);--dur-press:120ms;--dur-panel:280ms}
#content{animation:content-enter var(--dur-panel) var(--ease-out)}
@keyframes content-enter{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}
.action{transition:background .2s ease,color .2s ease,transform var(--dur-press) var(--ease-out)}

.unified-components{grid-template-columns:repeat(auto-fill,minmax(230px,1fr))!important}
.unified-components .thumbnail{aspect-ratio:4/3}
.unified-components video{width:100%;height:100%;object-fit:cover;background:#171717}
.reactbits-editor{display:block;width:100%;height:1200px;border:0;border-radius:24px;margin-top:36px;background:transparent}
/* Same 42px height, top and 10px gap as the saved/account circles in shell.css (saved: right 76px desktop, 68px narrow). */
.tools-entry{position:fixed;right:128px;top:18px;z-index:50;height:42px;min-height:42px;box-sizing:border-box;background:#fff}
.mobbin-site .context-preview{margin:0}
@media(max-width:760px){body .tools-entry{right:120px;top:16px;height:42px;min-height:42px}.unified-components{grid-template-columns:repeat(2,minmax(0,1fr))!important}.reactbits-editor{border-radius:12px}}
@media(prefers-reduced-motion:reduce){#content{animation:none}.action{transition:none}}
.reference-workspace{width:100%;padding-top:16px}
.reference-nav{display:flex;align-items:center;gap:24px;flex-wrap:wrap;margin:0 0 20px;font-size:14px;line-height:1.6;color:#171717}
.reference-nav a{padding:8px 0}
.reference-screen{display:block;width:100%;height:calc(100svh - 180px);min-height:560px;border:0;border-radius:20px;background:#fff}
body.account-mode .tools-entry,body.account-mode #gallery-switcher{display:none}
@media(max-width:759px){.reference-nav{gap:16px;flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;margin-inline:-20px;padding-inline:20px}.reference-nav a{white-space:nowrap}.reference-screen{height:calc(100svh - 200px);min-height:480px}.reference-workspace{padding-top:40px}}
/* Match the account adapter's control rhythm in the gallery shell. */
.reference-nav{column-gap:var(--space-6);row-gap:var(--space-2);margin-bottom:var(--space-6)}
.reference-nav a{display:inline-flex;align-items:center;min-height:var(--control-height);padding:var(--space-2) 0}
#gallery-sidebar #component-categories a,#gallery-sidebar #component-categories button{min-height:var(--control-height);padding:var(--space-2) var(--space-3);gap:var(--nav-icon-gap)}
.action{min-height:var(--control-height);gap:var(--icon-gap);padding:var(--space-2) var(--control-inset)}

/* Page background: React Bits DotField on white (dot-field.js); opacity as React Bits' Tools page in the light theme. */
.ambient{background:#fff!important}
.ambient .dot-field{opacity:1}
.ambient .dot-field canvas{opacity:1!important}
.account-mode .ambient::after{content:none!important}

/* Tools: lucide ToolCase (React Bits header) in the same 42px round control as the saved and account entries (shell.css .saved-entry). */
.tools-entry{display:grid!important;place-items:center;width:42px;height:42px!important;min-height:42px!important;padding:0!important;border-radius:50%!important;background:#fffffff2!important;box-shadow:0 4px 24px #1717170c;color:#191919}
/* ToolCase is drawn from many short strokes, so at the shared 1.6 width it reads lighter than the single-line bookmark and person; 2 matches their weight. */
.tools-entry svg{width:20px;height:20px;stroke-width:2!important;color:#191919}
/* Workspace screens float only the account button over the panel; the icon rule above must not bring Tools back. */
body.account-mode .tools-entry{display:none!important}
/* The lists' big headings (Websites / Components) are replaced by the top bar's row; hidden from the first paint so
   they do not flash before topbar.js has run. */
body.no-sidebar #content>.page-heading{display:none}
/* Before topbar.js has put the bars in, keep their room (nav 72 + gap 24 + filter row 64 + 8) so the cards do not
   draw at the top and then jump down. */
body.no-sidebar:not(:has(.tb-nav)) main#content{padding-top:calc(var(--tb-nav-h,72px) + 24px + var(--tb-slot-h,64px) + 8px)!important}
/* Until the top bar exists the page would appear in pieces (old corner buttons, a loading line, cards without the
   bar): keep everything but the dot ground out of sight, so the page appears at once with its bar. */
body.no-sidebar:not(:has(.tb-nav))>:not(.ambient):not(script){visibility:hidden;animation:tb-late 0s 3s forwards}
/* if the bar never comes (its script failed), show the page anyway after 3 s */
@keyframes tb-late{to{visibility:visible}}
/* the bell joins the top-right icons a moment later; show the group once it is complete so the icons do not shift */
.tb-nav-right:not(:has(.tb-bell)){visibility:hidden;animation:tb-late 0s 3s forwards}

/* Account content shares the gallery ambient ground. */
body.account-mode .reference-workspace:not(:has(.reference-nav))>iframe.reference-screen{background:transparent!important;box-shadow:none!important;border-radius:0}

/* Public recordings keep the edge-to-edge framing of the original live thumbnails. */
body #content .site-card.public-component-preview .thumbnail video{display:block;width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;object-fit:cover!important;margin:0;padding:0;border-radius:0;transform:none!important}
