/* Massimobility v1.40 — readable learning surfaces & isolated anatomy plates.
   Scoped presentation overrides; data banks, sources and interactions are untouched. */

/* Movement Library: correct dark hero / light body contrast conflict. */
body[data-page="movement.html"] .movement-hero{
  color:#f5fbff;
  background:radial-gradient(ellipse at 88% 14%,rgba(78,171,206,.20),transparent 49%),
             linear-gradient(120deg,#061b2a,#0b3047 74%,#123d53);
}
body[data-page="movement.html"] .movement-hero h1{color:#fff!important;letter-spacing:-.035em;line-height:1.08;}
body[data-page="movement.html"] .movement-hero h1 span{color:#8bdfff!important;}
body[data-page="movement.html"] .movement-hero .section-kicker{color:#a5eaff!important;}
body[data-page="movement.html"] .movement-hero :is(.movement-intro,.movement-mode-description){color:#e3f2f9!important;}
body[data-page="movement.html"] .movement-hero .movement-mode-switch{background:#0a2639;border-color:#39677e;}
body[data-page="movement.html"] .movement-hero .movement-mode-button{color:#e2f2fa;font-size:clamp(14px,1.2vw,16px);font-weight:700;line-height:1.4;min-width:0;}
body[data-page="movement.html"] .movement-hero .movement-mode-button.is-active{background:#1677a5;color:#fff;box-shadow:0 4px 15px rgba(0,0,0,.25);}
body[data-page="movement.html"] :is(.movement-feature,.movement-feature-grid section,.movement-context-grid>div,.movement-source-grid>a){min-width:0;}
body[data-page="movement.html"] .movement-feature{color:#203749;}
body[data-page="movement.html"] .movement-feature :is(h3,h4){font-family:var(--mm-heading,'Space Grotesk',sans-serif)!important;line-height:1.28;overflow-wrap:anywhere;}
body[data-page="movement.html"] .movement-feature h3{font-size:clamp(25px,2.8vw,38px);}
body[data-page="movement.html"] .movement-feature h4{font-size:clamp(16px,1.5vw,19px);}
body[data-page="movement.html"] .movement-feature :is(p,li){font-family:var(--mm-ui,'DM Sans',sans-serif)!important;color:#253e51;font-size:clamp(15px,1.16vw,17px);line-height:1.72;}
body[data-page="movement.html"] .movement-feature .movement-claim-source{font-size:13px;line-height:1.55;color:#334f62;}
body[data-page="movement.html"] .movement-feature .movement-claim-source a{color:#075c89;text-underline-offset:3px;overflow-wrap:anywhere;}
body[data-page="movement.html"] .movement-region-button{font-family:var(--mm-ui,'DM Sans',sans-serif)!important;font-size:clamp(13px,1vw,15px);line-height:1.45;}
body[data-page="movement.html"] .movement-feature-footer{align-items:baseline;}
body[data-page="movement.html"] .movement-feature-footer :is(a,span){font-size:14px;line-height:1.6;overflow-wrap:anywhere;}
/* Content has full contrast from the first animation frame: no dimmed/faded study text. */
@media(prefers-reduced-motion:no-preference){
  body[data-page="movement.html"] #movement-feature > *{
    animation:none!important;opacity:1!important;transform:none!important;
  }
  body[data-page="movement.html"] .movement-feature :is(p,li,h3,h4,a,span){animation:none!important;opacity:1!important;}
}
/* Do not let small viewport rules shrink classroom reading copy. */
@media(max-width:760px){
 body[data-page="movement.html"] .movement-hero{padding:clamp(30px,8vw,54px) 5vw 35px;}
 body[data-page="movement.html"] .movement-hero h1{font-size:clamp(33px,8.5vw,55px);}
 body[data-page="movement.html"] .movement-intro{font-size:16px;line-height:1.7;}
 body[data-page="movement.html"] .movement-mode-switch{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));max-width:100%;}
 body[data-page="movement.html"] .movement-mode-button{padding:13px 8px;min-height:48px;}
 body[data-page="movement.html"] .movement-feature :is(p,li){font-size:15px;}
 body[data-page="movement.html"] .movement-feature-grid{grid-template-columns:minmax(0,1fr);gap:16px;}
 body[data-page="movement.html"] .movement-feature-top{display:flex;flex-wrap:wrap;align-items:start;}
 body[data-page="movement.html"] .movement-feature-top>div{min-width:0;flex:1 1 100%;}
 body[data-page="movement.html"] .movement-context-grid>div{padding:20px;}
}
/* Focus reading view: uninterrupted copy and visible exit at all sizes. */
body[data-page="movement.html"] #movement-feature:fullscreen{overflow-y:auto;padding:clamp(22px,4vw,60px);background:#f6fafc;color:#172e3e;}
body[data-page="movement.html"] #movement-feature:fullscreen .movement-feature-grid{align-items:start;}
body[data-page="movement.html"] #movement-feature:fullscreen :is(h3,h4,p,li){opacity:1!important;}
body[data-page="movement.html"] #movement-feature:fullscreen .mm-movement-focus-exit{float:none;position:sticky;top:0;z-index:30;min-height:46px;}

/* Anatomical Mode: one complete selected plate per frame, no clipped neighbor gallery. */
body[data-page="anatomical-mode.html"] .mm-3d-viewport,
body[data-page="anatomical-mode.html"] .mm-3d-detail-frame{overflow:hidden;}
body[data-page="anatomical-mode.html"] .mm-3d-detail-frame{background:#020e1d;}
body[data-page="anatomical-mode.html"] .mm-3d-detail-frame img{
  display:block;width:100%;height:100%;max-width:100%;max-height:100%;
  object-fit:contain!important;object-position:center center!important;
  filter:none;image-rendering:auto;
}
body[data-page="anatomical-mode.html"] .mm-3d-detail-frame.is-visible{opacity:1;}
/* The interactive related-area cards remain below the viewer; a card displays one plate. */
body[data-page="anatomical-mode.html"] .mm-3d-gallery-view{overflow:hidden;}
body[data-page="anatomical-mode.html"] .mm-3d-gallery-view img{
  object-fit:contain!important;object-position:center!important;
  background:#031526;padding:3px;box-sizing:border-box;
}
/* No additional highlight/click overlay or guided-action buttons over the art.
   The anatomical key and its source links remain fully functional in the side panel. */
body[data-page="anatomical-mode.html"] .mm-3d-visual-labels,
body[data-page="anatomical-mode.html"] .mm-3d-focus-banner,
body[data-page="anatomical-mode.html"] .mm-3d-region-studio{display:none!important;}
body[data-page="anatomical-mode.html"] .mm-3d-hint{color:#c6deeb;font-size:clamp(12px,.95vw,14px);line-height:1.65;}
body[data-page="anatomical-mode.html"] .mm-3d-stage-head h2{font-family:var(--mm-heading,'Space Grotesk',sans-serif)!important;line-height:1.24;}
body[data-page="anatomical-mode.html"] .mm-3d-region-grid button,
body[data-page="anatomical-mode.html"] .mm-3d-structure-list button{line-height:1.45;overflow-wrap:anywhere;}
@media(max-width:690px){
 body[data-page="anatomical-mode.html"] .mm-3d-stage-card{padding:clamp(10px,3vw,16px);}
 body[data-page="anatomical-mode.html"] .mm-3d-viewport{height:clamp(470px,125vw,680px);}
 body[data-page="anatomical-mode.html"] .mm-3d-detail-frame img{object-fit:contain!important;}
 body[data-page="anatomical-mode.html"] .mm-3d-angle-strip{gap:10px;}
 body[data-page="anatomical-mode.html"] .mm-3d-gallery-view{flex-basis:clamp(118px,34vw,150px);}
 body[data-page="anatomical-mode.html"] .mm-3d-gallery-view img{height:clamp(76px,20vw,108px);}
 body[data-page="anatomical-mode.html"] .mm-3d-stage-head h2{font-size:clamp(17px,4.8vw,21px);}
}
@media(max-width:390px){
 body[data-page="anatomical-mode.html"] .mm-3d-viewport{height:clamp(445px,129vw,515px);}
}
@media(prefers-reduced-motion:reduce){
 body[data-page="anatomical-mode.html"] .mm-3d-detail-frame img{transition:none!important;}
}

/* v1.87: The anatomical artboard itself owns image labels and title. The
   duplicate floating label panel stays hidden; the independent right-hand
   anatomical terms panel remains interactive. */
body[data-page="anatomical-mode.html"] .mm-3d-experience .mm-3d-detail-frame img{
  width:100%!important;height:100%!important;max-width:100%!important;
  object-fit:contain!important;object-position:center!important;
}
