/* moduleone.ai/os, round 3 — the progress line of the demo in README.md (plan-runda-3.md §3). demo.js adds the markup; without
   JS and under prefers-reduced-motion none of it exists. Tone only, never a color: todo --rule, played --muted, playing --ink.
   The line stands on the side of the contents that faces the text (right of the column; under the strip on a phone). */
.dm-rail,.dm-line{display:none}
.dm-on .dm-rail{all:unset;box-sizing:border-box;position:absolute;right:0;width:var(--dm-gutter);display:block;cursor:pointer;opacity:0;transition:opacity .3s ease-out}
.dm-live .dm-rail{opacity:1}
.dm-rail:focus-visible{outline:2px solid var(--ink);outline-offset:2px;border-radius:6px}
/* the sign: pause (two bars) while it plays, play (a triangle) when paused or at rest */
.dm-g{position:absolute;left:50%;top:-6px;width:24px;height:24px;margin-left:-12px;color:var(--muted);transition:color .15s ease-out}
.dm-g::before,.dm-g::after{content:"";position:absolute;top:8px;width:2.5px;height:8px;border-radius:1px;background:currentColor}
.dm-g::before{left:8.25px}.dm-g::after{left:13.25px}
.dm-paused .dm-g::after{display:none}
.dm-paused .dm-g::before{left:9px;top:8px;width:0;height:0;border-radius:0;background:none;border-style:solid;border-width:4px 0 4px 7px;border-color:transparent transparent transparent currentColor}
.dm-rail:hover .dm-g,.dm-rail:focus-visible .dm-g{color:var(--ink)}
/* one segment per item: a 2 px track, the played part filled from the top */
.dm-seg{position:absolute;display:block;overflow:hidden;border-radius:1px;background:var(--rule);transition:background-color .15s ease-out}
.dm-rail .dm-seg{left:11px;width:2px}
.dm-seg>i{position:absolute;inset:0;display:block;background:var(--ink);transform:scaleY(var(--p,0));transform-origin:50% 0;opacity:0}
.dm-seg[data-state="done"]{background:var(--muted)}
.dm-seg[data-state="playing"]>i{opacity:1}
/* the items of the contents follow the demo in tone; the plate still means only "you are reading here" */
.dm-on .uk-toc a[data-demo="playing"]{color:var(--ink)}
.dm-on .uk-toc a[data-demo="done"]{color:var(--ink-2)}
.dm-on .uk-toc a{transition:color .15s ease-out,background-color var(--t-ui) ease-out}
@media (hover:none) and (min-width:900px){:root{--dm-gutter:44px}.dm-rail .dm-seg{left:21px}}

/* the strip (up to 899 px): a pause button at the right end, the line of nine segments replaces the strip's bottom rule */
@media (max-width:899px){
  .dm-on .uk-toc{box-shadow:none}
  .dm-on .uk-toc-l{padding-right:52px;-webkit-mask-image:linear-gradient(90deg,transparent 0,#000 12px,#000 calc(100% - 68px),transparent calc(100% - 52px));mask-image:linear-gradient(90deg,transparent 0,#000 12px,#000 calc(100% - 68px),transparent calc(100% - 52px))}
  .dm-on .dm-rail{top:0;right:0;width:44px;height:44px;z-index:1}
  .dm-on .dm-rail .dm-seg{display:none}
  .dm-on .dm-g{top:10px}
  .dm-on .dm-line{position:absolute;left:var(--gut);right:var(--gut);bottom:0;height:2px;display:flex;gap:3px;pointer-events:none}
  .dm-line .dm-seg{position:relative;flex:1 1 0;height:2px}
  .dm-line .dm-seg>i{transform:scaleX(var(--p,0));transform-origin:0 50%}
  html:not(.dm-on) .uk-toc{box-shadow:0 1px 0 var(--rule)}
}
@media (prefers-reduced-motion:reduce){.dm-rail,.dm-line{display:none!important}}
