/* Feld-Grafik der Notiz „Das Feld, vermessen“ (ADR 0385).
   Nur Tinte, Ton und Schraffur: keine Farbe, die bewertet (Verzicht 11).
   Alle Regeln unter .fv, damit nichts mit main.css kollidiert. */

.fv {
  --page: var(--color-page); --ink: var(--color-ink); --ink-soft: var(--color-ink-soft);
  --muted: var(--color-muted); --faint: var(--color-faint); --rule: var(--color-rule);
  --line: var(--color-line); --hair: var(--color-hairline); --accent: var(--color-accent);
  --tone: #e2e0d8;
  --mono: ui-monospace, "Consolas", monospace;
  --serif: "EB Garamond", Garamond, Georgia, serif;
  text-align: left; hyphens: manual; -webkit-hyphens: manual;
  position: relative;
  margin: 1.6rem 0 1.4rem;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .fv { --tone: #33322d; } }
:root[data-theme="dark"] .fv { --tone: #33322d; }

/* Der Textkoerper bleibt 36em breit; nur die Grafiken nutzen die volle Breite. */
.blk-body:has(> .fv-breit) { max-width: none; }
.blk-body:has(> .fv-breit) > :not(.fv-breit) { max-width: 36em; }

.fv p, .blk-body .fv p + p { text-indent: 0; margin: 0 0 .5rem; }
.fv .fv-tafel h3 { text-transform: none; letter-spacing: 0; font-size: 1rem; }
.fv-ohne-js { font-style: italic; color: var(--faint); }
.fv button { font: inherit; color: var(--ink); background: var(--page); border: 0; cursor: pointer; }
.fv button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.fv-mono { font-family: var(--mono); font-size: .68rem; letter-spacing: .05em; }

.fv-tip { position: absolute; pointer-events: none; background: var(--page); border: 1px solid var(--ink); padding: .4rem .55rem; font-size: .75rem; line-height: 1.35; max-width: 270px; box-shadow: 3px 3px 0 var(--tone); z-index: 5; }
.fv-tip b { font-weight: 600; }
.fv-tip .fv-m { font-family: var(--mono); font-size: .62rem; color: var(--muted); }

/* Steuerung */
.fv-steuer { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1.3rem; margin: 0 0 1.4rem; font-family: var(--mono); font-size: .68rem; color: var(--muted); }
.fv-achse { display: inline-flex; align-items: center; gap: .45rem; }
.fv-seg { display: inline-flex; border: 1px solid var(--rule); }
.fv-seg button { width: 2rem; height: 2rem; border-left: 1px solid var(--hair); font-family: var(--mono); font-size: .7rem; }
.fv-seg button:first-child { border-left: 0; }
.fv-seg button[aria-pressed="true"] { background: var(--ink); color: var(--page); }
.fv-seg-b button { width: auto; padding: 0 .65rem; }
.fv .fv-zurueck { border: 1px solid var(--rule) !important; padding: .4rem .7rem; font-family: var(--mono); font-size: .7rem; }

/* Körper */
.fv-koerper { display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr); gap: 1.6rem; align-items: center; margin: 0 0 1.6rem; }
.fv-koerper svg { width: 100%; height: auto; display: block; }
.fv-koerper p { font-size: .84rem; color: var(--ink-soft); line-height: 1.45; max-width: 40ch; }
.fv-ko-zelle { fill: var(--page); stroke: var(--line); stroke-width: .8; cursor: pointer; }
.fv-ko-zelle:hover { fill: var(--tone); }
.fv-ko-t { font-family: var(--mono); font-size: 11px; fill: var(--ink); }
.fv-ko-tick { font-family: var(--mono); font-size: 9px; fill: var(--muted); }
.fv-ko-achse { font-family: var(--mono); font-size: 9.5px; letter-spacing: .07em; fill: var(--faint); }

/* Raster */
.fv-raster { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.6rem 1.2rem; }
.fv-tafel { min-width: 0; display: flex; flex-direction: column; gap: .3rem; }
.fv-tafel h3 { margin: 0; font-weight: 600; font-size: .92rem; line-height: 1.2; text-align: left; }
.fv-unter { font-size: .74rem; color: var(--muted); line-height: 1.3; min-height: 2.5em; }
.fv-tafel svg { width: 100%; max-width: 240px; height: auto; display: block; }
.fv-legende { display: flex; flex-wrap: wrap; gap: .15rem .8rem; font-size: .74rem; color: var(--ink-soft); line-height: 1.3; }
.fv-legende span { display: inline-flex; align-items: center; gap: .35rem; }
.fv-legende svg { width: 12px; height: 12px; flex: none; }
.fv-zaehl { font-family: var(--mono); font-size: .62rem; color: var(--faint); }
.fv-befund { font-family: var(--mono); font-size: .64rem; border-top: 1px solid var(--hair); padding-top: .35rem; color: var(--muted); }
.fv-befund b { color: var(--ink); font-weight: 600; }
.fv-ohneb { color: var(--faint); }
.fv-notiz { font-size: .72rem; color: var(--faint); line-height: 1.35; }
.fv-lese { border-top: 1px solid var(--ink); padding-top: .5rem; font-size: .78rem; line-height: 1.4; color: var(--ink-soft); }
.fv-zelle { cursor: pointer; }
.fv-zelle:hover { stroke: var(--ink); stroke-width: 1.4; }

\1 {
  .fv-raster { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fv-koerper { grid-template-columns: minmax(0, 1fr); }
  .fv-koerper svg { max-width: 360px; }
}
@media (max-width: 540px) {
  .fv-raster { grid-template-columns: minmax(0, 1fr); }
  .fv-tafel svg { max-width: 280px; }
  .fv-unter { min-height: 0; }
}
