/* Lage (Auftrag A, 12.11.2026; UMBAUPLAN „Endgültige Festlegungen“, Teil Lage; drawn by public/lage.js). A box like the
   Steckbrief: graphite head with "LAGE" in lime, 1.5 px rule around. Three lines, each a label in small caps like „FAKTEN“,
   the facts in serif with figures in Plex Mono semibold; only the price change in --up/--down, no traffic-light colours.
   Logical properties only (RTL), colours only from public/style.css, no fade-in with reduced motion.
   E1 (12.11.2026, Feinschliff): the facts of a line flow like a sentence at the normal line height (with a mouse; a touch screen
   keeps 44 px tap targets, a box up to 520 px wide 32 px), the label stays in its own column, also on a phone (it costs no
   line of its own there). The dot between two facts is the fact's ::before in its start; the line of facts is moved by that
   width to the start and clipped, so a line never ends or starts with a dot. Before: 44 px between wrapped lines on a
   desktop, one fact per line on a phone (the fullest Lage over 500 px high at 390 px, "Beobachten" below the first screen). */

/* Figures in mono semibold inside a serif sentence without splitting the sentence (i18n.js translates each text whole,
   docs/I18N.md): a face that covers digits, $, %, + and the minus sign only; every other letter falls through to the serif. */
@font-face{font-family:"TRACER Lage Ziffern";font-style:normal;font-weight:100 900;font-display:swap;src:url(/fonts/ibm-plex-mono-latin-600-normal.woff2) format("woff2");unicode-range:U+0024-0025,U+002B,U+0030-0039,U+2212}

/* --lage-line: the height of one line of facts and of every tap target in it; --lage-sep: the room of the dot. */
.lage{--lage-line:26px;--lage-sep:1.05em;container-type:inline-size;border:1.5px solid var(--rule);border-radius:14px;background:var(--surface);overflow:hidden}
/* The head: "LAGE", then "Stand vor …" and "Als Text kopieren" at its end; as high as before with a mouse (36 px). */
.lage-head{display:flex;align-items:center;flex-wrap:wrap;gap:2px 14px;padding-block:max(2px,calc((36px - var(--lage-line)) / 2));padding-inline:20px 10px;background:var(--graphite)}
.lage-title{margin:0;font:700 12px var(--sans);letter-spacing:.1em;text-transform:uppercase;color:var(--lime)}
.lage-stand{margin-inline-start:auto;font:500 12.5px var(--sans);color:var(--on-dark-muted)}

/* One label column for all three lines (subgrid), as wide as the widest label in the reader's language. */
.lage-rows{display:grid;grid-template-columns:minmax(6.5em,max-content) minmax(0,1fr);column-gap:14px;margin:0;padding-block:4px;padding-inline:20px}
.lage-row{display:grid;grid-column:1/-1;grid-template-columns:subgrid;align-items:start;padding-block:5px;border-block-start:1px solid var(--line-soft)}
.lage-row:first-of-type{border-block-start:0}
.lage-label{font:700 11px/var(--lage-line) var(--sans);letter-spacing:.09em;text-transform:uppercase;color:var(--green-ink)}
.lage-items{min-inline-size:0;margin:0;overflow:hidden;font:400 16px/1.35 "TRACER Lage Ziffern",var(--serif);color:var(--fg)}
.lage-flow{display:block;margin-inline-start:calc(-1 * var(--lage-sep))}
/* A fact with its dot: wraps as a whole; its text wraps like a sentence when it is longer than the line. */
.lage-fact{display:inline-flex;align-items:center;max-inline-size:100%;vertical-align:top}
.lage-fact::before{content:"·";content:"·" / "";flex:none;inline-size:var(--lage-sep);text-align:center;color:var(--faint)}
.lage-fact:first-child::before{visibility:hidden}
/* The fact itself: its own bidi island, so a number never swaps sides with its words in Arabic, Hebrew, Persian or Urdu. */
.lage-item{display:inline-flex;align-items:center;min-block-size:var(--lage-line);min-inline-size:0;margin:0;padding-block:2px;padding-inline:4px;border:0;border-radius:8px;
  background:none;color:inherit;font:inherit;text-align:start;unicode-bidi:isolate}
/* Its words take the direction of their first letter: an Arabic translation runs right to left, German not yet translated
   stays "−19 % in 1 Std." on an Arabic page (seen as ".in 1 Std % 19−" with the page's direction, 12.11.2026). */
.lage-text,.lage-stand{unicode-bidi:plaintext}
button.lage-item{cursor:pointer}
button.lage-item:hover{background:var(--lime-wash)}
button.lage-item:focus-visible{outline:2px solid var(--accent);outline-offset:-2px}
.lage-item.is-up{color:var(--up)}
.lage-item.is-down{color:var(--down)}
/* Loading: the dash holds the place of its fact, so nothing moves when the value comes. */
.lage-item.is-pending{min-inline-size:2.5em;justify-content:center;color:var(--faint)}
.lage-empty{display:inline-block;padding-inline:var(--lage-sep) 4px;font:400 14px/var(--lage-line) var(--sans);color:var(--muted)}
.lage-item.is-new{animation:lage-in .3s var(--ease) both}
@keyframes lage-in{from{opacity:0}to{opacity:1}}
@media (prefers-reduced-motion:reduce){.lage-item.is-new{animation:none}}

.lage-copy{min-block-size:var(--lage-line);padding-inline:10px;border:0;border-radius:8px;background:transparent;color:var(--lime);font:600 12.5px var(--sans);cursor:pointer}
.lage-stand[hidden]+.lage-copy{margin-inline-start:auto}
.lage-copy:hover{background:var(--graphite-2)}
.lage-copy:focus-visible{outline:2px solid var(--lime);outline-offset:-3px}
.lage-copy:disabled{color:var(--on-dark-muted);cursor:default}

/* A touch screen: 44 px tap targets. */
@media (pointer:coarse){.lage{--lage-line:44px}}
/* Without subgrid: a fixed label column. */
@supports not (grid-template-columns:subgrid){.lage-row{grid-template-columns:6.5em minmax(0,1fr);column-gap:14px}}

/* Narrow boxes (a phone): the label column as narrow as its words, smaller type and lines, 32 px tap targets. Measured at
   390 px (box 358 px, E1, 12.11.2026): the fullest Lage (three facts, two, three; long words) 324 px high instead of 373 px with
   a footer of its own, so "Beobachten" stays on the first screen. */
@container (max-width:520px){
  .lage-head{--lage-line:32px;padding-inline:14px 6px}
  .lage-rows{--lage-line:32px;grid-template-columns:max-content minmax(0,1fr);column-gap:8px;padding-block:2px;padding-inline:10px}
  .lage-row{padding-block:3px}
  .lage-items{font-size:15px;line-height:1.25}
  .lage-label{font-size:10.5px}
  @supports not (grid-template-columns:subgrid){.lage-row{grid-template-columns:4.8em minmax(0,1fr);column-gap:8px}}
}
