/* css/otter/phase3.css (4 November 2026, marigold otter, Phase 3: design-research/marigold-otter/SPEC.md 3.1 to 3.4 and the four fixes). Linked LAST in index.html, after cards.css.
   WHAT IT DOES, on the four map levels (Century, City, Micro-market, Area) only; the Site and the levels after it are untouched:
     1 · the merged Trust card's own button (Documents), on the card's foot row beside More.
     2 · ONE "more" behaviour on the bottom strip: the old "+N" tab (css/ux/qa-fixes.css, mf-chrome.css: a badge that sat on the last visible item and covered its text, and could not be tapped) is replaced by a soft fade at the edge that has
         more, as the topic row has; the one count left on a strip is the real "+N more" chip of an Area list (css/otter/cards.css 2), an item that adds the rest of the places.
   Tokens are R13's; no custom property on <body>, no [style*=], no :has(); the level lists use :is([data-level=...]) on body, as cards.css does. */

/* ---------- 1 · the card's own button: Documents ---------- */
html.r13 body #lv-map .info .ot-act-b { position: relative; flex: none; margin-left: auto; display: inline-flex; align-items: center; min-height: var(--q-chip); padding: 0 var(--s4); border: 0; border-radius: var(--r-capsule); background: var(--lg-field-hi); color: var(--fg);
  font: var(--ty-callout); letter-spacing: var(--tr-callout); cursor: pointer; -webkit-tap-highlight-color: transparent; }
html.r13 body #lv-map .info .ot-act-b::after { content: ""; position: absolute; inset: calc(-6px * var(--ui-scale)) calc(-8px * var(--ui-scale)); }   /* a 44px hit box around the 32px capsule, as More has */
html.r13 body #lv-map .info .ot-act-b:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; }
html.r13 body.glass-day #lv-map .info .ot-act-b { background: rgba(22, 22, 27, .08); }
@media (prefers-contrast: more) { html.r13 body #lv-map .info .ot-act-b { box-shadow: inset 0 0 0 1.5px currentColor; } }
html.r13 body #lv-map .info :is(.info-ghost, .mm-ghost) .ot-act-b { display: none !important; }

/* ---------- 2 · one "more" behaviour on the bottom strip ---------- */
/* The tab counted the chips that sat past the right edge and was drawn over the last visible one (Hospitals: "+12" on top of the fourth place's name). On these four levels the edge that has more fades into the strip's own tone
   instead (a sticky gradient pseudo-element with no text, pointer-events none: nothing to cover, nothing that invites a tap it cannot answer); the strip scrolls sideways as it always did. The strip's own edge mask (css/showroom.css) is
   switched off on the right so the capsule itself stays whole; a strip scrolled away from its start keeps the old fade on the left. */
html.r13 body:is([data-level=century], [data-level=city], [data-level=market], [data-level=area]) #ctx .strip.more-r { -webkit-mask-image: none; mask-image: none; }
html.r13 body:is([data-level=century], [data-level=city], [data-level=market], [data-level=area]) #ctx .strip.more-r.more-l { -webkit-mask-image: linear-gradient(90deg, transparent, #000 4rem); mask-image: linear-gradient(90deg, transparent, #000 4rem); }
html.r13 body:is([data-level=century], [data-level=city], [data-level=market], [data-level=area]) #ctx .strip.more-r::after,
html.r13 body:is([data-level=century], [data-level=city], [data-level=market], [data-level=area]) #ctx .strip[data-more]::after {
  content: ""; position: sticky; right: 0; flex: none; align-self: stretch; display: block; width: 3rem; min-width: 0; height: auto; margin: 0 0 0 -3rem; padding: 0; border-radius: 0 var(--r-pill) var(--r-pill) 0;
  background: linear-gradient(90deg, rgba(24, 24, 28, 0), rgb(24, 24, 28) 85%); box-shadow: none; color: transparent; font-size: 0; pointer-events: none; z-index: 2; animation: none; }
html.r13 body.glass-day:is([data-level=century], [data-level=city], [data-level=market], [data-level=area]) #ctx .strip.more-r::after,
html.r13 body.glass-day:is([data-level=century], [data-level=city], [data-level=market], [data-level=area]) #ctx .strip[data-more]::after { background: linear-gradient(90deg, rgba(246, 246, 247, 0), rgb(246, 246, 247) 85%); box-shadow: none; }

/* ---------- 3 · the next button stays in one place on the four levels ---------- */
/* Measured (design-research/marigold-otter/log-P3.md): at 1280x800 the button stood at y 679 on Century, City and Area, 636 on every Micro-market topic (css/r13/scene.css 10a lifted it over the era strip that ran to the sun dial) and 625 over Then & now
   (css/ux/map.css, css/ux/mf-chrome.css raised it over the scrubber); the baseline did the same. The era strip is a City topic now, so the Micro-market loses its lift, and Then & now's scrubber stops short of the button the way every strip does, so
   the raise goes too. On the TV the button was level with the knob on Century only (css/r13/chrome.css) and 46px higher on City and Area: Century's place is the one for all four. The Site and the levels after it keep their own rules. */
@media (orientation: landscape) {
  html.r13 body.has-cta[data-level=market] #ui > #cta.on, html.r13 body.tl-on[data-level=market] #ui > #cta.on { right: calc(var(--pad) + 12.4rem + var(--safe-r)); bottom: calc(var(--pad) + 3.5rem + var(--safe-b)); }   /* the values every other rule of the button ends with on Century, City and Area (css/ux/map.css "body #cta") */
  html.r13 body.has-cta[data-level=market]:not(.tl-on) #ui#ui #ctx#ctx { right: calc(var(--pad) + 12.4rem + var(--safe-r) + var(--cta-w, 11rem) + var(--s4) * var(--ui-scale)); }   /* as Century, City and Area (css/r13/chrome.css): the strip stops a gap short of the button */
  html.r13 body.tl-on[data-level=market] #lv-map .tl-bar { right: calc(var(--pad) + 12.4rem + var(--safe-r) + var(--cta-w, 11rem) + var(--s4) * var(--ui-scale)); }   /* the scrubber stops where the strips do */
  html.r13.tv body:is([data-level=century], [data-level=city], [data-level=market], [data-level=area]) #ui > #cta.on, html.r13.tv body.tl-on[data-level=market] #ui > #cta.on { bottom: calc(var(--gutter) + var(--safe-b) + (var(--orb-zone) - var(--q-ctl)) / 2); }
}

/* ---------- 4 · an open card: the foot row sits at the card's bottom edge, and the scrolling part uses the room above it ---------- */
/* Phase 2 left the foot (Less) 22 to 33px above the bottom of an open card that scrolls and 14px or more of empty card under it: the card's own 2.4rem of bottom padding (.ux-scroll) stayed outside the sticky band, whose long shadow was
   hiding the rows that scrolled under it. An open card has no bottom padding now: the foot is its last 52px (8 above the button, 12 below), opaque, glued to the card's bottom edge at the top of the scroll, in the middle and at the end, and
   the rows scroll in everything above it. A card that fits is the same card with the same foot. */
html.r13 body:is([data-level=century], [data-level=city], [data-level=market], [data-level=area]) #lv-map .info.ot-open { padding-bottom: 0; }
html.r13 body #lv-map .info.ot-open > .ot-foot { bottom: 0; padding: var(--s2) 0 var(--s3); margin: 0; background: none; box-shadow: none; }   /* (4 November, otter, review fixes, item 10) the band's own tone (#1c1c1e, #e9e9e6) went: it read as a different box, a lighter one, and cut a row mid-text; css/otter/review.css 4 gives it the card's own backdrop and a soft fade above */
