/* Virtual Tour Studio 55.1.2 — UI Micro-Polish / 2500 Grit.
   Narrow fixes only: laptop/tablet/landscape breakpoints, touch hit areas,
   auth width safety, microtype readability, accessibility names and first-use compaction. */

/* Shared auth shell: keep the editorial layout, but never let it exceed the viewport. */
body.v5512-ui-polish.auth-page{overflow-x:hidden!important}
body.v5512-ui-polish.auth-page .auth-shell{
  box-sizing:border-box!important;
  width:min(1420px,100%)!important;
  max-width:none!important;
  grid-template-columns:minmax(0,1fr) minmax(400px,470px)!important;
  gap:clamp(28px,3.2vw,52px)!important;
  padding:40px clamp(24px,4vw,64px)!important;
}
body.v5512-ui-polish.auth-page .auth-brand{left:clamp(24px,4vw,64px)!important}
body.v5512-ui-polish.auth-page .auth-shell::after{
  left:clamp(24px,4vw,64px)!important;
  max-width:min(470px,42vw)!important;
  top:calc(50% + 105px)!important;
}
body.v5512-ui-polish.auth-page .auth-card{box-sizing:border-box!important;width:min(470px,100%)!important;max-width:100%!important}
body.v5512-ui-polish.auth-page .auth-card h1{font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif!important;font-weight:720!important}
@media(max-width:1180px){
  body.v5512-ui-polish.auth-page .auth-shell{display:flex!important;min-height:100vh!important;align-items:center!important;justify-content:center!important;padding:88px 18px 28px!important}
  body.v5512-ui-polish.auth-page .auth-shell::before,body.v5512-ui-polish.auth-page .auth-shell::after{display:none!important}
  body.v5512-ui-polish.auth-page .auth-brand{left:18px!important;top:20px!important}
  body.v5512-ui-polish.auth-page .auth-card{width:min(510px,100%)!important}
}

/* Commercial Center: never show a blank navigation rail in the 761–1050 band. */
@media(min-width:761px) and (max-width:1050px){
  body.v5512-ui-polish .commercial-shell{grid-template-columns:176px minmax(0,1fr)!important}
  body.v5512-ui-polish .commercial-sidebar{padding:18px 10px!important}
  body.v5512-ui-polish .commercial-brand{justify-content:flex-start!important;padding:4px 8px 18px!important}
  body.v5512-ui-polish .commercial-brand span{display:grid!important}
  body.v5512-ui-polish .commercial-brand small{display:none!important}
  body.v5512-ui-polish .commercial-sidebar nav span{display:inline!important;font-size:11px!important;white-space:nowrap!important}
  body.v5512-ui-polish .commercial-sidebar nav button{display:flex!important;align-items:center!important;justify-content:flex-start!important;min-height:44px!important;height:44px!important;padding:0 10px!important;text-align:left!important}
  body.v5512-ui-polish .commercial-back{display:flex!important;min-height:44px!important;align-items:center!important;padding:0 8px!important;font-size:10px!important}
}

/* CRM connections: progressive disclosure, one calm provider card at a time. */
body.v5512-ui-polish .v5512-provider-toggle{
  width:100%;min-height:44px;border:1px solid var(--c-line,#e4e7ec);border-radius:11px;background:#f8f9fb;color:inherit;
  display:flex;align-items:center;justify-content:space-between;gap:12px;padding:0 12px;font:inherit;font-weight:750;cursor:pointer
}
body.v5512-ui-polish .v5512-provider-toggle::after{content:'＋';font-size:18px;font-weight:500;color:#727987}
body.v5512-ui-polish .v5512-provider-toggle[aria-expanded="true"]::after{content:'−'}
body.v5512-ui-polish .v5512-provider-form[hidden]{display:none!important}
body.v5512-ui-polish .v5512-provider-form{margin-top:12px}

/* Publish Center: no meaningful 8–9px text, and slightly stronger secondary copy. */
body.v5512-ui-polish.pc-page :is(.pc-brand small,.pc-project span,.pc-save-state,.pc-release-card>span,.pc-release-card>small,.pc-team span,.pc-brand-preview span,.pc-workflow-step span,.pc-issue span){
  font-size:max(10.5px,0.66rem)!important;color:#667085!important;line-height:1.4!important
}
body.v5512-ui-polish.pc-page .pc-kicker{font-size:11px!important}
body.v5512-ui-polish.pc-page .pc-score span{font-size:10.5px!important}

/* Studio: keep the repaired dock but make labels readable. */
@media(max-width:860px){
  body.v5512-ui-polish.v22-studio .v528-author-tool .v529-tool-caption{font-size:10.5px!important;line-height:1.05!important}
}

/* Dashboard: the glyph may stay compact; the actual button must be finger-sized. */
body.v5512-ui-polish.v47-dashboard #mobileMenuButton{width:44px!important;min-width:44px!important;height:44px!important;min-height:44px!important;display:grid!important;place-items:center!important}

/* Spatial Capture first use: reduce empty-session chrome and keep brand link named/reachable. */
body.v5512-ui-polish .spatial-topbar .brand{min-height:44px}
@media(max-width:680px){
  body.v5512-ui-polish.v5512-no-captures main{display:block!important}
  body.v5512-ui-polish.v5512-no-captures .capture-sidebar{width:100%!important;min-height:0!important;padding:8px 12px!important;display:block!important;border-right:0!important;border-bottom:1px solid var(--sp-line,#dfe4ed)!important}
  body.v5512-ui-polish.v5512-no-captures .capture-sidebar .sidebar-head{min-height:48px!important;padding:0!important}
  body.v5512-ui-polish.v5512-no-captures .capture-sidebar .sidebar-head .eyebrow{display:none!important}
  body.v5512-ui-polish.v5512-no-captures .capture-sidebar .sidebar-head h1{font-size:15px!important;margin:0!important}
  body.v5512-ui-polish.v5512-no-captures .capture-sidebar .runtime-card,
  body.v5512-ui-polish.v5512-no-captures .capture-sidebar .capture-list,
  body.v5512-ui-polish.v5512-no-captures .capture-sidebar .sidebar-note{display:none!important}
  body.v5512-ui-polish.v5512-no-captures .capture-workspace{margin:0!important;padding:18px 12px 28px!important;border:0!important;border-radius:0!important}
  body.v5512-ui-polish.v5512-no-captures .empty-workspace{margin:12px auto 0!important}
  body.v5512-ui-polish .spatial-topbar .brand{min-width:44px!important}
}

/* Public player: normalize the last information toggle to the same touch contract. */
body.v5512-ui-polish.v11-tour #informationHotspotsToggle{min-width:44px!important;width:44px!important;min-height:44px!important;height:44px!important}

/* Touch modality matters more than width alone. This catches landscape phones/tablets. */
@media(any-pointer:coarse), (max-height:520px) and (max-width:1000px){
  body.v5512-ui-polish.v47-dashboard :is(#mobileMenuButton,.v47-top-actions button,.v47-mobile-nav button,.v47-top-actions .primary){min-width:44px!important;min-height:44px!important}
  body.v5512-ui-polish.v22-studio :is(.topbar .brand,.top-actions .btn,.top-actions .icon-btn,.top-actions .v484-more,.viewer-controls button){min-width:44px!important;min-height:44px!important;height:44px!important}
  body.v5512-ui-polish.pc-page :is(.pc-btn,.pc-tabs button,.pc-mobile-tabs button){min-height:44px!important;height:44px!important}
  body.v5512-ui-polish .commercial-sidebar nav button,body.v5512-ui-polish .commercial-main :is(button,.btn,select){min-height:44px!important}
  body.v5512-ui-polish .spatial-shell :is(.btn,.icon-action,.top-actions a,.top-actions button,.stepper button){min-height:44px!important}
  body.v5512-ui-polish.v11-tour :is(.tour-actions button,.viewer-controls button,#informationHotspotsToggle){min-width:44px!important;min-height:44px!important}
}

@media(prefers-reduced-motion:reduce){
  body.v5512-ui-polish *{scroll-behavior:auto!important}
}

/* 55.1.2 gate hardening: override older high-specificity publish microtype. */
html body.v5512-ui-polish.pc-page.pc-body.v5160-publish.v5150-publish-premium.v5171-quality-stability .pc-release-card>span,
html body.v5512-ui-polish.pc-page.pc-body .pc-release-card>span{
  font-size:10.5px!important;
  color:#667085!important;
  line-height:1.4!important;
}
@media(max-width:680px){
  body.v5512-ui-polish #newCapture{
    width:44px!important;min-width:44px!important;height:44px!important;min-height:44px!important;
  }
}
@media(any-pointer:coarse), (max-height:520px) and (max-width:1000px){
  body.v5512-ui-polish.v22-studio.v529-precision-shell .top-actions .v484-more{
    width:44px!important;min-width:44px!important;max-width:44px!important;
    height:44px!important;min-height:44px!important;max-height:44px!important;
    flex:0 0 44px!important;box-sizing:border-box!important;
  }
}
@media(any-pointer:coarse), (max-height:520px) and (max-width:1000px){
  body.v5512-ui-polish.v22-studio #v484More{
    width:44px!important;min-width:44px!important;max-width:44px!important;
    height:44px!important;min-height:44px!important;max-height:44px!important;
    flex:0 0 44px!important;
  }
}

/* v56.1.0 — Video → 3D starter hub. Product-first empty state. */
body.v22-studio .starter-hub{position:absolute;inset:22px;display:grid;align-content:center;gap:18px;padding:26px;border:1px solid rgba(108,117,140,.12);border-radius:22px;background:linear-gradient(180deg,rgba(252,253,255,.96),rgba(246,248,252,.94));backdrop-filter:blur(14px);box-shadow:0 24px 60px rgba(17,24,39,.08);z-index:4;overflow:auto}
body.v22-studio .starter-copy{max-width:760px}
body.v22-studio .starter-eyebrow{display:inline-flex;align-items:center;gap:6px;padding:6px 10px;border-radius:999px;background:rgba(91,87,232,.1);color:#5b57e8;font-size:12px;font-weight:700;letter-spacing:.02em;text-transform:uppercase}
body.v22-studio .starter-copy h2{margin:12px 0 10px;font-size:34px;line-height:1.06;letter-spacing:-.04em;color:#151821}
body.v22-studio .starter-copy p{margin:0;color:#5d6474;font-size:15px;line-height:1.6;max-width:820px}
body.v22-studio .starter-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
body.v22-studio .starter-card{position:relative;display:flex;align-items:flex-start;gap:14px;min-height:112px;padding:18px;border:1px solid rgba(206,212,222,.9);border-radius:18px;background:#fff;color:#151821;text-align:left;cursor:pointer;transition:transform .18s ease,box-shadow .18s ease,border-color .18s ease,background .18s ease}
body.v22-studio .starter-card:hover{transform:translateY(-1px);border-color:rgba(91,87,232,.28);box-shadow:0 18px 34px rgba(24,32,56,.08)}
body.v22-studio .starter-card i{display:grid;place-items:center;min-width:42px;width:42px;height:42px;border-radius:14px;background:rgba(91,87,232,.1);color:#5b57e8;font-style:normal;font-size:18px;font-weight:800}
body.v22-studio .starter-card span{display:grid;gap:6px;min-width:0}
body.v22-studio .starter-card b{font-size:16px;line-height:1.25}
body.v22-studio .starter-card small{display:block!important;color:#61687a;font-size:13px!important;line-height:1.45}
body.v22-studio .starter-card em{margin-left:auto;align-self:flex-start;padding:6px 10px;border-radius:999px;background:#f3f4f8;color:#5a6072;font-style:normal;font-size:11px;font-weight:700;white-space:nowrap}
body.v22-studio .starter-card.primary{border-color:rgba(91,87,232,.3);background:linear-gradient(180deg,rgba(241,239,255,.92),rgba(255,255,255,.98))}
body.v22-studio .starter-card.primary em{background:#5b57e8;color:#fff}
body.v22-studio .starter-card.ghost{background:#fbfbfd}
body.v22-studio.has-scenes .starter-hub{display:none!important}
@media (max-width:1080px){body.v22-studio .starter-hub{inset:16px;padding:20px}body.v22-studio .starter-copy h2{font-size:28px}body.v22-studio .starter-grid{grid-template-columns:1fr}}
@media (max-width:760px){body.v22-studio .starter-hub{position:absolute;inset:8px;margin:0;border-radius:18px;padding:16px;align-content:start}body.v22-studio .starter-copy h2{font-size:23px}body.v22-studio .starter-copy p{font-size:13px;line-height:1.45}body.v22-studio .starter-grid{gap:10px}body.v22-studio .starter-card{min-height:86px;padding:14px}body.v22-studio .starter-card em{margin-left:0;font-size:10px}}
