/* Website in Gestaltung A „Schaltwarte" (Auftrag 127, Vorlage .claude/auftraege/127-entwurf/a-schaltwarte.html):
   immer dunkel (Marke), feines Raster, Cyan als einzige Akzentfarbe, Messwerte in Festbreitenschrift. Ruhig nach
   docs/01 Abschnitt 1: eine Flächenebene, wenige Linien, höchstens ein hervorgehobener Knopf je Seite. Keine fremden
   Schriften, keine Bilder von außen; Bewegung nur am Schnittbild der Startseite und nicht bei „weniger Bewegung".
   Gedruckt wird hell. */
:root {
  color-scheme: dark;
  --bg: #070b11;
  --panel: #0d141d;
  --line: #1b2633;
  --line-strong: #2c3a4a;
  --grid: rgba(110, 190, 230, 0.06);
  --text: #e6edf3;
  --muted: #8a98a8;
  --cyan: #5fd4f0;
  --cyan-soft: rgba(95, 212, 240, 0.14);
  --on-cyan: #04121a;
  --amber: #f2b441;
  --amber-soft: rgba(242, 180, 65, 0.1);
  --mono: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  --gutter: clamp(16px, 5vw, 64px);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background-color: var(--bg);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 32px 32px;
  color: var(--text);
  font: 16px/1.6 system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-variant-numeric: tabular-nums;
  overflow-wrap: break-word;
}
a { color: var(--cyan); }
a:hover { color: var(--text); }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 12px; }
h1 { font-size: clamp(30px, 4.2vw, 52px); font-weight: 650; letter-spacing: -0.02em; }
h2 { font-size: 22px; font-weight: 650; margin-top: 48px; }
h3 { font-size: 16px; font-weight: 650; margin-top: 24px; }
h4 { font-size: 15px; font-weight: 650; margin: 20px 0 8px; }
p { margin: 0 0 12px; }
ul { margin: 0 0 12px; padding-left: 22px; }
li { margin-bottom: 4px; }
code { font-family: var(--mono); font-size: 0.9em; background: var(--panel); border: 1px solid var(--line); padding: 0 5px; border-radius: 4px; }
.muted { color: var(--muted); }
/* Sprungziele nicht unter dem stehenden Kopf */
[id] { scroll-margin-top: 88px; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: 16px; top: -48px; color: var(--text); }
.skip:focus { top: 8px; background: var(--bg); padding: 4px 8px; z-index: 10; }

/* Kopf: Logo, Navigation, Anmelden mit dem einen umrandeten Knopf, Sprache */
.top {
  position: sticky; top: 0; z-index: 5; border-bottom: 1px solid var(--line);
  background: rgba(7, 11, 17, 0.88); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.top .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 28px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: inline-flex; color: var(--text); line-height: 0; }
.logo { height: 30px; width: auto; display: block; }
/* In dieser Größe wäre die Leitung kaum ein Pixel breit: kräftiger gezeichnet als in der Datei */
.logo path[stroke] { stroke-width: 36; }
.nav { display: flex; flex-wrap: wrap; gap: 4px 22px; flex: 1 1 auto; font-size: 14px; }
.nav a, .actions a.plain { color: var(--muted); text-decoration: none; white-space: nowrap; }
.nav a:hover, .actions a.plain:hover { color: var(--text); }
.nav a[aria-current='page'] { color: var(--text); box-shadow: inset 0 -1px 0 var(--cyan); }
.actions { display: flex; align-items: center; gap: 14px; margin-left: auto; font-size: 14px; }
.lang { font-family: var(--mono); color: var(--muted); text-decoration: none; font-size: 13px; letter-spacing: 0.06em; }

.button {
  display: inline-block; padding: 9px 18px; border: 1px solid var(--cyan); border-radius: 4px;
  background: transparent; color: var(--cyan); text-decoration: none; font-weight: 500; white-space: nowrap;
}
.button:hover { background: var(--cyan-soft); color: var(--cyan); }
.button.primary { background: var(--cyan); color: var(--on-cyan); font-weight: 600; }
.button.primary:hover { filter: brightness(1.08); color: var(--on-cyan); }
.button.small { padding: 5px 13px; }

main.wrap { padding-top: 48px; padding-bottom: 72px; }
.lead { font-size: 18px; color: var(--muted); max-width: 40em; }
.label { font-size: 13px; text-transform: uppercase; letter-spacing: 0.18em; color: var(--muted); font-weight: 600; }
.more { margin-top: 16px; font-size: 15px; }

/* Startseite: Text links, Schnittbild mit Fadenkreuz und Messwerten rechts */
.hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 40px; align-items: center; padding: 16px 0 24px; }
.hero h1 { margin: 0 0 18px; }
.hero .row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 28px; }
.hero .row .button { padding: 11px 20px; font-size: 15px; }
.scope { position: relative; margin: 0; width: 100%; max-width: 540px; justify-self: center; }
.scope .section { display: block; width: 100%; height: auto; aspect-ratio: 1; overflow: visible; }
.readouts { margin: 0; font-family: var(--mono); letter-spacing: 0.02em; font-size: 12px; color: var(--muted); line-height: 1.35; }
.readout { position: absolute; }
.readout dt { margin: 0; }
.readout dd { margin: 0; }
.readout b { display: block; color: var(--text); font-size: 15px; font-weight: 600; }
.readout .ok, .readout .dot { color: var(--cyan); }
.r1 { left: 0; top: 5%; }
.r2 { right: 0; top: 12%; text-align: right; }
.r3 { right: 0; bottom: 12%; text-align: right; }
.r4 { left: 0; bottom: 8%; }
.scope figcaption { font-family: var(--mono); font-size: 11px; color: var(--muted); text-align: center; margin-top: 4px; letter-spacing: 0.04em; }
/* Der Läufer dreht langsam, die Abtastlinie läuft um; beide um ihren Mittelpunkt, die Achse der Maschine */
.spin { transform-box: fill-box; transform-origin: center; animation: spin 66s linear infinite; }
.spin.sweep { animation-duration: 10s; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .spin { animation: none; }
  .sweep { display: none; }
}

/* Schritte des Wegs: Leiste mit nummerierten Knoten */
.rail { list-style: none; padding: 0; margin: 24px 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); position: relative; counter-reset: step; }
.rail::before { content: ''; position: absolute; top: 13px; left: 13px; right: 13px; height: 1px; background: linear-gradient(90deg, var(--cyan), rgba(95, 212, 240, 0.15)); }
.rail li { position: relative; padding-right: 24px; margin: 0; counter-increment: step; }
.rail li::before {
  content: counter(step); display: grid; place-items: center; width: 27px; height: 27px; border-radius: 50%;
  border: 1px solid var(--cyan); background: var(--bg); color: var(--cyan); font: 12px/1 var(--mono);
}
.rail h3 { margin: 16px 0 6px; }
.rail p { margin: 0; color: var(--muted); font-size: 14px; }

/* Maschinenarten: Karten mit Schnittbild */
.types { list-style: none; padding: 0; margin: 20px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr)); gap: 16px; }
.types li { margin: 0; }
.types a {
  display: block; height: 100%; padding: 16px; border: 1px solid var(--line); border-radius: 8px; color: var(--text);
  text-decoration: none; background: linear-gradient(180deg, rgba(13, 20, 29, 0.92), rgba(13, 20, 29, 0.65)); transition: border-color 0.2s;
}
.types a:hover { border-color: rgba(95, 212, 240, 0.5); color: var(--text); }
.types .section, .machine .section { display: block; width: 100%; height: auto; aspect-ratio: 1; }
.types span { display: block; margin-top: 10px; font-size: 14px; }

/* Drei Zusagen und andere Paare: Linie oben, Text gedämpft */
.pairs { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 8px 32px; margin-top: 16px; }
.pairs div { padding: 16px 0 8px; border-top: 1px solid var(--line); }
.pairs h3 { margin: 0 0 6px; font-size: 16px; }
.pairs p { margin: 0; color: var(--muted); font-size: 15px; }

/* Funktionen: je Maschinenart eine Karte */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 520px), 1fr)); gap: 16px; margin-top: 16px; }
.card { border: 1px solid var(--line); border-radius: 8px; padding: 20px; background: rgba(13, 20, 29, 0.85); }
.card h3 { margin-top: 0; }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
.card ul { color: var(--muted); font-size: 15px; }
.machine { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 20px; align-items: start; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; padding: 0; list-style: none; }
.tags li { margin: 0; font: 12px/1.6 var(--mono); color: var(--cyan); border: 1px solid rgba(95, 212, 240, 0.35); border-radius: 3px; padding: 0 7px; }

/* Preise: vier Tarife nebeneinander, darunter die Regeln */
.plans { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 28px; }
.plan { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 8px; padding: 20px; background: rgba(13, 20, 29, 0.85); }
.plan h2 { margin: 0; font-size: 13px; text-transform: uppercase; letter-spacing: 0.16em; color: var(--cyan); }
.plan .price { font-size: 26px; font-weight: 650; margin: 12px 0 0; white-space: nowrap; }
.plan .alt { color: var(--muted); margin: 0 0 12px; font-size: 14px; }
.plan ul { list-style: none; padding: 0; margin: 12px 0 16px; font-size: 14px; }
.plan li { padding: 7px 0; border-top: 1px solid var(--line); margin: 0; }
.plan .cta { margin-top: auto; }
.rules { max-width: 760px; }
.note { color: var(--muted); font-size: 14px; margin-top: 16px; }

/* Rechtstexte: ruhige Fläche ohne Raster, Zeilen nicht zu lang */
.legal { max-width: 46em; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 32px 40px; font-size: 16px; line-height: 1.7; }
.legal h1 { font-size: 30px; letter-spacing: -0.01em; }
.legal h2 { font-size: 19px; margin-top: 36px; }
.legal p, .legal li { color: #d3dbe3; }
.legal blockquote { margin: 0 0 24px; padding: 10px 14px; border-left: 3px solid var(--amber); background: var(--amber-soft); }
.legal blockquote p { margin: 0; color: var(--text); }
.table { overflow-x: auto; margin: 0 0 16px; }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { text-align: left; vertical-align: top; padding: 8px 10px; border-bottom: 1px solid var(--line); }
th { font-weight: 650; color: var(--muted); font-size: 13px; text-transform: uppercase; letter-spacing: 0.08em; }
.notice { margin: 8px 0 0; font-size: 14px; color: var(--muted); }

.foot { border-top: 1px solid var(--line); padding: 24px 0 40px; font-size: 13px; color: var(--muted); background: rgba(7, 11, 17, 0.9); }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-bottom: 8px; }
.foot a { color: var(--muted); }
.foot a:hover, .foot a[aria-current='page'] { color: var(--text); }

@media (max-width: 960px) {
  .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  /* Schnittbild unter dem Text; die Messwerte stehen darunter als Liste */
  .scope { max-width: 440px; }
  .readouts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 20px; margin-top: 12px; }
  .readout { position: static; text-align: left; }
  .rail { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 0; }
  .rail::before { display: none; }
}
@media (max-width: 600px) {
  main.wrap { padding-top: 28px; }
  .lead { font-size: 17px; }
  .logo { height: 26px; }
  .plans, .rail { grid-template-columns: minmax(0, 1fr); }
  /* Leiste senkrecht: Knoten links, Text daneben */
  .rail { gap: 20px; }
  .rail::before { display: block; top: 13px; bottom: 13px; left: 13px; right: auto; width: 1px; height: auto; background: linear-gradient(180deg, var(--cyan), rgba(95, 212, 240, 0.15)); }
  .rail li { display: grid; grid-template-columns: 27px minmax(0, 1fr); column-gap: 16px; padding-right: 0; }
  .rail li::before { grid-row: 1 / span 2; }
  .rail h3 { margin: 3px 0 4px; }
  .rail p { grid-column: 2; }
  /* Der Kopf braucht hier drei Zeilen: Er rollt mit, statt stehen zu bleiben */
  .top { position: static; }
  .top .wrap { gap: 8px 16px; padding-top: 12px; padding-bottom: 10px; }
  .nav { order: 3; flex-basis: 100%; gap: 4px 18px; }
  .actions { gap: 12px; }
  .types { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .types a { padding: 12px; }
  .machine { grid-template-columns: minmax(0, 1fr); }
  .machine .section { max-width: 160px; }
  .legal { padding: 20px 18px; }
  /* Tabellen als Folge von Zeilen untereinander, jede Zelle mit der Bezeichnung ihrer Spalte */
  table, tbody, tr, td { display: block; width: 100%; }
  thead { display: none; }
  tr { border-bottom: 1px solid var(--line); padding: 8px 0; }
  td { border: 0; padding: 2px 0; }
  td::before { content: attr(data-label); display: block; font-size: 13px; color: var(--muted); }
}

/* Druck: hell, ohne Raster, Navigation und Knöpfe; Rechtstexte in voller Breite */
@media print {
  :root { --text: #000; --muted: #333; --line: #bbb; --panel: #fff; --bg: #fff; --cyan: #1c7fa0; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .top { position: static; background: none; backdrop-filter: none; border-bottom: 1px solid #bbb; }
  .nav, .actions, .skip, .foot nav, .scope, .button { display: none; }
  .brand { color: #14181d; }
  .logo path[stroke] { stroke: #1c7fa0; }
  .logo circle { fill: #1c7fa0; }
  .legal { max-width: none; border: 0; padding: 0; background: none; }
  .legal p, .legal li { color: #000; }
  .legal blockquote { background: none; border-left-color: #8a5a00; }
  a { color: #000; }
  .card, .plan, .types a, .foot { background: none; }
}
