/* SUP128 — MH Glass contrast correction + moving optical reflection.
   Dedicated CSS overlay only; all logos, existing animations and functional JS are untouched. */
:root{--mh128-edge:rgba(167,25,43,.26);--mh128-light:#fff8f9;--mh128-ink:#23191e;}
@keyframes mh128-optical-drift{
  0%,8%{background-position:-230% 0}
  42%,100%{background-position:230% 0}
}
@keyframes mh128-glass-breathe{
  0%,100%{box-shadow:0 8px 26px rgba(65,14,26,.095),inset 0 1px rgba(255,255,255,.76)}
  50%{box-shadow:0 12px 33px rgba(65,14,26,.135),inset 0 1px rgba(255,255,255,.91)}
}
@media(prefers-reduced-motion:reduce){
  :is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread),:is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread)::after{animation:none!important;transition:none!important}
}
@media(prefers-reduced-transparency:reduce){
  :is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread){backdrop-filter:none!important;-webkit-backdrop-filter:none!important}
}
@supports not (backdrop-filter:blur(1px)){
  :is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread){background-color:rgba(255,250,251,.99)!important}
}

/* Glass sheen moves over the surface itself, not the text. */
@media(prefers-reduced-motion:no-preference){
  :is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread){animation:mh128-glass-breathe 11s ease-in-out infinite;}
  :is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread)::after{
    content:"";position:absolute;inset:0;display:block;
    pointer-events:none;z-index:1;border-radius:inherit;
    background-image:linear-gradient(108deg,transparent 28%,rgba(255,255,255,.018) 37%,rgba(255,255,255,.26) 47%,rgba(255,255,255,.045) 53%,transparent 64%);
    background-repeat:no-repeat;background-size:240% 100%;
    animation:mh128-optical-drift 10s cubic-bezier(.38,.09,.55,.93) infinite;
    opacity:.46;will-change:background-position;
  }
}
:is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread){
  position:relative;isolation:isolate;
  -webkit-backdrop-filter:blur(15px) saturate(145%);backdrop-filter:blur(15px) saturate(145%);
  border:1px solid var(--mh128-edge)!important;
  box-shadow:0 8px 28px rgba(48,12,23,.1),inset 0 1px rgba(255,255,255,.86)!important;
  border-radius:16px;overflow:hidden;
}
@media(hover:hover) and (prefers-reduced-motion:no-preference){
  :is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread):hover{transform:translateY(-2px);box-shadow:0 14px 30px rgba(48,12,23,.15),inset 0 1px rgba(255,255,255,.95)!important}
}
@media(max-width:700px){
  :is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread){-webkit-backdrop-filter:blur(9px) saturate(132%);backdrop-filter:blur(9px) saturate(132%)}
  :is(.mh128-glass-motion,body #office .card.stat,body #office .workflow-card,body #office .mh20-card,body #office .mh105-thread)::after{animation-duration:14s;opacity:.28}
}

/* Office records, tables and money fields: clear light surface with dark ink. */
html body #office .mh128-glass-motion:is(.card,.stat,.workflow-card,.mh20-card,.mh105-thread),
html body #office .mh128-glass-motion:is(.card,.stat,.workflow-card,.mh20-card,.mh105-thread):not(button){
 background:linear-gradient(133deg,rgba(255,255,255,.97),rgba(255,246,248,.90))!important;
 background-color:#fffafa!important;color:#251c21!important;
}
html body #office .mh128-glass-motion :is(h1,h2,h3,h4,strong){color:#21191c}
html body #office .mh128-glass-motion :is(p,small,label,.muted){color:#51434b;opacity:1}
html body #office .mh128-glass-motion :is(input,textarea,select){
 background:#fff!important;color:#20171a!important;
}
html body #office .mh128-glass-motion :is(th,td){color:#281f23}

/* SUP125 office metrics used background:none with high-specificity !important,
   override without recoloring status indicators. */
html body #office article.card.stat,
html body #office article.card.stat.mh-metric-clickable,
html body #office section.card.panel,
html body #office article.card.panel {
 background-image:linear-gradient(135deg,rgba(255,255,255,.98),rgba(255,245,248,.87))!important;
 background-color:#fffafa!important;
 color:#251a21!important;
 border-color:rgba(167,25,43,.24)!important;
}
html body #office article.card.stat :is(p,small,label){color:#51434b!important;opacity:1!important}
