/* Eikus · #2 One video (js/widgets/eikus-folder.js): one two-character clip ("badge") taken apart into its folder.
   Drawn on a canvas with 1px lines and flat marks; every word is an HTML label on top so the page's translation
   table reaches it. No fills behind panels, no shadows. */

[data-widget="eikus-folder"] { display: block; color: var(--ink); }
.ef { position: relative; }

/* ---- steps and controls: mono text buttons on one rule ---- */
.ef-top { display: flex; align-items: flex-end; justify-content: space-between; gap: calc(12 * var(--u)) calc(24 * var(--u)); flex-wrap: wrap;
  margin: 0 0 calc(22 * var(--u)); border-bottom: 1px solid var(--line); }
.ef-steps { display: flex; gap: 0 clamp(calc(14 * var(--u)), calc(2vw * var(--f)), calc(28 * var(--u))); min-width: 0; }
.ef-step { position: relative; display: inline-flex; align-items: baseline; gap: calc(8 * var(--u)); padding: 0 0 calc(11 * var(--u)); margin: 0;
  font: 400 calc(12 * var(--u))/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; white-space: nowrap;
  color: var(--ink-3); background: none; border: 0; cursor: pointer; transition: color .3s var(--ease-io); }
.ef-step .n { font-size: calc(11 * var(--u)); color: var(--ink-3); opacity: .75; }
.ef-step:hover, .ef-step[aria-current="step"] { color: var(--ink); }
.ef-step[aria-current="step"] .n { color: var(--amber); opacity: 1; }
.ef-prog { position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: var(--amber);
  transform: scaleX(0); transform-origin: 0 50%; pointer-events: none; }
.ef-step:focus-visible { outline: 1px solid var(--amber); outline-offset: calc(4 * var(--u)); }

.ef-ctl { display: flex; gap: calc(8 * var(--u)); padding: 0 0 calc(8 * var(--u)); }
.ef-btn { padding: calc(6 * var(--u)) calc(10 * var(--u)) calc(5 * var(--u)); font: 400 calc(11 * var(--u))/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; white-space: nowrap;
  color: var(--ink-3); background: none; border: 1px solid var(--line); border-radius: calc(2 * var(--u)); cursor: pointer;
  transition: color .3s var(--ease-io), border-color .3s var(--ease-io); }
.ef-btn:hover { color: var(--ink); border-color: var(--ink-3); }
.ef-btn:focus-visible { outline: 1px solid var(--amber); outline-offset: calc(2 * var(--u)); }
.ef-sound[aria-pressed="true"] { color: var(--amber); border-color: var(--amber); }

/* ---- the stage: videos under the canvas, words over it ---- */
.ef-stage { position: relative; width: 100%; overflow: hidden; contain: layout paint; }
.ef-vids, .ef-cv, .ef-labs { position: absolute; left: 0; top: 0; }
.ef-cv { display: block; pointer-events: none; }
.ef-labs { width: 100%; height: 100%; pointer-events: none; }
.ef-vids { width: 100%; height: 100%; }
.ef-vid { position: absolute; left: 0; top: 0; display: block; max-width: none; max-height: none; object-fit: cover; transform-origin: 0 0; background: var(--cocoa);
  pointer-events: none; visibility: hidden; }

.ef-l { position: absolute; left: 0; top: 0; white-space: nowrap; visibility: hidden; opacity: 0;
  font-family: var(--mono); font-size: calc(12 * var(--u)); line-height: 1; letter-spacing: .02em; color: var(--ink-2); }
.ef-r { translate: -100% -50%; }
.ef-key { font-size: calc(12 * var(--u)); letter-spacing: .09em; text-transform: uppercase; color: var(--ink-3); }
.ef-name { white-space: normal; line-height: 1.3; transition: color .5s var(--ease-io); }
.ef-name.is-new { color: var(--orange); }
.ef-name.is-lit { color: var(--orange); }
.ef-ro { translate: -100% 0; font-size: calc(12 * var(--u)); color: var(--ink-2); font-variant-numeric: tabular-nums; }
.ef-big { font-family: var(--sans); font-stretch: var(--expanded); font-weight: 800; font-size: clamp(calc(30 * var(--u)), calc(3.4vw * var(--f)), calc(44 * var(--u)));
  line-height: 1.02; letter-spacing: -.01em; color: var(--ink); white-space: normal; }
.ef-total { translate: -100% 0; font-family: var(--sans); font-stretch: var(--expanded); font-weight: 800; font-size: calc(26 * var(--u));
  line-height: 1; color: var(--ink); font-variant-numeric: tabular-nums; }
.ef-total, .ef-ro { white-space: nowrap; }
[data-widget="eikus-folder"] .ef-key.ef-tot { translate: -100% 0; }
.ef-tag { padding: calc(4 * var(--u)) calc(6 * var(--u)) calc(3 * var(--u)); font-size: calc(11 * var(--u)); letter-spacing: .1em; color: var(--ink); background: var(--charcoal);
  border: 1px solid var(--ink); border-radius: calc(2 * var(--u)); }
.ef-code { translate: -50% 0; font-size: calc(10 * var(--u)); letter-spacing: .1em; color: var(--ink-3); }
.ef-code.ef-r { translate: -100% -50%; }
.ef-cue { font-size: calc(11 * var(--u)); color: var(--amber); }
/* dubbing: what the app does with the sound bed, on the bed's own lane */
.ef-bednote { white-space: normal; font-size: calc(11 * var(--u)); line-height: 1.25; letter-spacing: 0; color: var(--ink-2); }
/* the two characters: two quiet colours (olive, fog); orange stays for what is new */
.ef-rl { font-size: calc(11 * var(--u)); }
.ef-rl[data-role="A"]::before, .ef-rl[data-role="B"]::before { content: ""; display: inline-block; width: calc(7 * var(--u)); height: calc(7 * var(--u)); margin-right: calc(7 * var(--u));
  background: var(--olive); transform: translateY(-1px); }
.ef-rl[data-role="B"]::before { background: var(--fog); }
.ef-you { font-size: calc(11 * var(--u)); color: var(--orange); }
.ef-muted { translate: -50% -50%; padding: calc(2 * var(--u)) calc(4 * var(--u)) 1px; font-size: calc(10 * var(--u)); letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-2); background: var(--bg); }
.ef-rkey { display: flex; gap: calc(12 * var(--u)); font-size: calc(11 * var(--u)); color: var(--ink-3); }
.ef-rkey.ef-r0 { translate: -100% 0; }
.ef-k { display: inline-flex; align-items: baseline; gap: calc(6 * var(--u)); }
.ef-k::before { content: ""; flex: none; width: calc(7 * var(--u)); height: calc(7 * var(--u)); background: var(--olive); transform: translateY(-1px); }
.ef-k-b::before { background: var(--fog); }
.ef-roletag { font-size: calc(10 * var(--u)); letter-spacing: .1em; text-transform: uppercase; color: var(--olive); }
.ef-roletag[data-role="B"] { color: var(--fog); }
.ef-script .ef-sl-a { color: var(--olive); }
.ef-script .ef-sl-b { color: var(--fog); }
.ef-stop { translate: -50% 0; color: var(--orange); }
/* the app's own choices: how you record, whom you dub; the one in use is orange */
.ef-dub, .ef-hold { display: flex; flex-direction: column; gap: calc(8 * var(--u)); white-space: normal; }
.ef-row { display: flex; flex-wrap: wrap; gap: calc(6 * var(--u)) calc(22 * var(--u)); }
.ef-opt { display: inline-flex; gap: calc(9 * var(--u)); align-items: baseline; font-size: calc(12 * var(--u)); line-height: 1.35; color: var(--ink-3);
  transition: color .35s var(--ease-io); }
.ef-opt::before { content: ""; flex: none; width: calc(7 * var(--u)); height: calc(7 * var(--u)); border: 1px solid currentColor; transform: translateY(-1px); }
.ef-opt.is-on { color: var(--orange); }
.ef-opt.is-on::before { background: var(--orange); }
.ef-holdb { font-size: calc(12 * var(--u)); line-height: 1.35; color: var(--ink-2); padding-left: calc(18 * var(--u)); }
.ef-ax { translate: -50% 0; font-size: calc(10 * var(--u)); letter-spacing: .04em; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.ef-ax.ef-end { translate: -100% 0; }
.ef-ax.ef-start { translate: 0 0; }
.ef-ph { translate: -50% 0; font-size: calc(11 * var(--u)); color: var(--amber); font-variant-numeric: tabular-nums; }
/* the lines that do not fit wrap onto a hidden second row, so none is cut in the middle */
.ef-script { display: flex; flex-wrap: wrap; gap: 0 calc(14 * var(--u)); height: 1.25em; line-height: 1.25; overflow: hidden; font-size: calc(11 * var(--u)); color: var(--ink-2); }
/* the sentence in four languages: one block, so a line too long for a phone wraps and pushes the next one down */
.ef-sents { display: flex; flex-direction: column; gap: calc(3 * var(--u)); }
.ef-sent { display: flex; align-items: baseline; gap: calc(10 * var(--u)); font-size: calc(13 * var(--u)); line-height: 1.15; color: var(--ink); }
.ef-sent[hidden] { display: none; }
.ef-sent b { flex: none; width: calc(20 * var(--u)); font-weight: 400; font-size: calc(10 * var(--u)); letter-spacing: .1em; color: var(--ink-3); }
.ef-sent span { min-width: 0; white-space: normal; }
.ef-szv { font-family: var(--sans); font-stretch: var(--expanded); font-weight: 800; font-size: calc(22 * var(--u)); color: var(--ink);
  font-variant-numeric: tabular-nums; }

/* ---- phones: the same story re-arranged; step names only for the step you are on ---- */
.ef.is-phone .ef-top { margin-bottom: calc(18 * var(--u)); }
.ef.is-phone .ef-steps { width: 100%; justify-content: space-between; gap: 0 calc(6 * var(--u)); }
.ef.is-phone .ef-step:not([aria-current="step"]) .t { display: none; }
.ef.is-phone .ef-step { font-size: calc(11 * var(--u)); letter-spacing: .06em; gap: calc(6 * var(--u)); }
/* narrower: the buttons go above, so the steps keep sitting on the rule */
.ef.is-narrow .ef-ctl { order: -1; margin-left: auto; padding: 0 0 calc(4 * var(--u)); }
.ef.is-narrow .ef-steps { width: 100%; }
.ef.is-phone .ef-key { font-size: calc(11 * var(--u)); letter-spacing: .08em; }
.ef.is-phone .ef-ro { font-size: calc(11 * var(--u)); }
.ef.is-phone .ef-big { font-size: calc(24 * var(--u)); }
.ef.is-phone .ef-total { font-size: calc(20 * var(--u)); }
.ef.is-phone .ef-szv { font-size: calc(18 * var(--u)); }
.ef.is-phone .ef-sents { gap: calc(7 * var(--u)); }
.ef.is-phone .ef-sent { font-size: calc(12 * var(--u)); line-height: 1.3; gap: calc(8 * var(--u)); }
.ef.is-phone .ef-opt, .ef.is-phone .ef-holdb { font-size: calc(11 * var(--u)); }
.ef.is-phone .ef-dub, .ef.is-phone .ef-hold { gap: calc(10 * var(--u)); }
.ef.is-phone .ef-row { flex-direction: column; gap: calc(5 * var(--u)); }
.ef.is-phone .ef-holdb { padding-left: 0; }
.ef.is-phone .ef-cue, .ef.is-phone .ef-bednote { font-size: calc(10 * var(--u)); }
.ef.is-phone .ef-tag { font-size: calc(10 * var(--u)); padding: calc(3 * var(--u)) calc(5 * var(--u)) calc(2 * var(--u)); }
