/* Büro Romig – Stylesheet
   Keine externen Schriften oder Dienste (DSGVO-freundlich). */

:root {
  --paper: #f6f7f5;
  --white: #ffffff;
  --ink: #1c2329;
  --muted: #56616a;
  --line: #cfd5d9;
  --signal: #1f7a4d;       /* angelehnt an Sicherheitsgrün RAL 6032 */
  --signal-dark: #155a38;

  --font-display: "Bahnschrift", "DIN Alternate", "DIN Next", "D-DIN", "Roboto Condensed", "Arial Narrow", sans-serif;
  --font-text: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --wrap: 72rem;
  --pad: clamp(1.25rem, 4vw, 2.5rem);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: 1.0625rem;
  line-height: 1.6;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--signal); text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { color: var(--signal-dark); text-decoration-thickness: 2px; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--signal); outline-offset: 3px; border-radius: 2px; }

.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: var(--white); padding: .5rem 1rem; z-index: 10; }
.skip:focus { left: 1rem; top: 1rem; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--pad); }

/* ---------- Kopfbereich ---------- */
.site-header { border-bottom: 1px solid var(--line); background: var(--white); }
.site-header .wrap {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: .75rem 2rem; padding-top: 1.1rem; padding-bottom: 1.1rem;
}
.brand { text-decoration: none; color: var(--ink); display: flex; align-items: center; gap: .75rem; }
.brand:hover { color: var(--ink); }
.brand-mark { width: 2.1rem; height: 2.1rem; background: var(--signal); flex: none; position: relative; }
.brand-mark::after { content: ""; position: absolute; inset: .45rem .45rem auto auto; width: .7rem; height: .7rem; background: var(--white); }
.brand-name { font-family: var(--font-display); font-weight: 700; font-size: 1.35rem; line-height: 1.1; display: block; }
.brand-sub { font-size: .85rem; color: var(--muted); display: block; line-height: 1.2; }

.nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .25rem 1.5rem; }
.nav a {
  font-family: var(--font-display); font-size: 1.05rem; color: var(--ink); text-decoration: none;
  padding: .3rem 0; border-bottom: 2px solid transparent;
}
.nav a:hover { border-bottom-color: var(--line); color: var(--ink); }
.nav a[aria-current="page"] { border-bottom-color: var(--signal); color: var(--signal); }

/* ---------- Inhalt ---------- */
main { padding-bottom: 2rem; }

.page-head { padding: clamp(3rem, 8vw, 5.5rem) 0 clamp(2rem, 5vw, 3rem); }
.page-head.hero {
  background-image:
    repeating-linear-gradient(0deg, transparent 0 31px, rgba(28,35,41,.05) 31px 32px),
    repeating-linear-gradient(90deg, transparent 0 31px, rgba(28,35,41,.05) 31px 32px);
}

h1, h2, h3 { font-family: var(--font-display); font-weight: 700; line-height: 1.15; margin: 0; }
h1 { font-size: clamp(2.2rem, 5.5vw, 3.75rem); line-height: 1.06; max-width: 20ch; letter-spacing: -.01em; }
h2 { font-size: clamp(1.35rem, 2.4vw, 1.65rem); }
h3 { font-size: 1.2rem; }

.lead { font-size: clamp(1.15rem, 2vw, 1.3rem); max-width: 60ch; margin: 1.5rem 0 0; }

p { max-width: 68ch; margin: 0 0 1rem; }

/* Abschnitt: Überschrift links, Inhalt rechts – wie Plankopf und Planinhalt */
.sect {
  display: grid; grid-template-columns: minmax(11rem, 1fr) 3fr; gap: 1rem 3rem;
  border-top: 1px solid var(--ink); padding: 1.5rem 0 3.5rem;
}
.sect > h2 { padding-top: .1rem; }
.sect-body > :last-child { margin-bottom: 0; }

/* Leistungsliste */
.spec { list-style: none; margin: 0; padding: 0; }
.spec li {
  display: grid; grid-template-columns: minmax(12rem, 1fr) 2fr; gap: .25rem 2rem;
  padding: .8rem 0; border-bottom: 1px solid var(--line);
}
.spec li:first-child { padding-top: 0; }
.spec strong { font-weight: 600; }
.spec span { color: var(--muted); }

.cols { columns: 3 12rem; column-gap: 2rem; margin: 0; padding: 0; list-style: none; }
.cols li { break-inside: avoid; padding: .35rem 0; border-bottom: 1px solid var(--line); }

.linklist { list-style: none; margin: 0; padding: 0; }
.linklist li { border-bottom: 1px solid var(--line); }
.linklist a {
  display: grid; grid-template-columns: minmax(12rem, 1fr) 2fr; gap: .25rem 2rem;
  padding: 1rem 0; text-decoration: none; color: var(--ink);
}
.linklist a strong { font-family: var(--font-display); font-size: 1.2rem; color: var(--signal); }
.linklist a:hover strong { text-decoration: underline; text-underline-offset: .2em; }
.linklist a span { color: var(--muted); }

.note { color: var(--muted); font-size: .95rem; }

/* ---------- Referenzen ---------- */
.refs { border-top: 1px solid var(--ink); }
.ref {
  display: grid; grid-template-columns: 8rem minmax(0, 2fr) minmax(12rem, 1fr); gap: .5rem 2rem;
  padding: 1.5rem 0; border-bottom: 1px solid var(--line);
}
.ref-year { font-family: var(--font-display); font-size: 1.1rem; font-variant-numeric: tabular-nums; color: var(--muted); }
.ref h2 { font-size: 1.3rem; }
.ref-place { color: var(--muted); margin: .15rem 0 .6rem; }
.ref p:last-child { margin-bottom: 0; }
.ref-scope { margin: 0; padding: 0; list-style: none; font-size: .95rem; }
.ref-scope li { padding-left: .9rem; position: relative; }
.ref-scope li::before { content: ""; position: absolute; left: 0; top: .6em; width: .4rem; height: .4rem; background: var(--signal); }
.ref figure { margin: 1rem 0 0; }
.ref figcaption { font-size: .9rem; color: var(--muted); margin-top: .35rem; }

/* ---------- Kontakt ---------- */
.contact-main { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: 1.5rem 3rem; }
.contact-main p { margin: 0; }
.big-link { font-family: var(--font-display); font-size: 1.35rem; }

.team { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 0 2.5rem; margin: 0; padding: 0; list-style: none; }
.team li { padding: 1rem 0; border-bottom: 1px solid var(--line); }
.team .name { font-weight: 600; display: block; }
.team .role { color: var(--muted); display: block; font-size: .95rem; margin-bottom: .35rem; }
.team a { font-size: .95rem; }

/* ---------- Rechtstexte ---------- */
.legal h3 { margin: 1.75rem 0 .5rem; font-size: 1.1rem; }
.legal h3:first-child { margin-top: 0; }
.legal address { font-style: normal; margin-bottom: 1rem; }

/* ---------- Fußbereich als Plankopf ---------- */
.site-footer { padding: 3rem 0 2.5rem; }
.titleblock {
  display: grid; grid-template-columns: 2fr 1.6fr 1.2fr 1fr;
  border: 2px solid var(--ink); background: var(--white);
}
.tb-cell { padding: .7rem .9rem; border-right: 1px solid var(--ink); border-bottom: 1px solid var(--ink); min-width: 0; }
.tb-cell:nth-child(4n) { border-right: 0; }
.tb-cell:nth-last-child(-n+4) { border-bottom: 0; }
.tb-label { display: block; font-size: .75rem; color: var(--muted); line-height: 1.3; }
.tb-value { display: block; font-family: var(--font-display); font-size: 1rem; line-height: 1.35; overflow-wrap: anywhere; }
.tb-value a { color: var(--ink); }
.tb-value a:hover { color: var(--signal); }
.tb-firm .tb-value { font-size: 1.15rem; font-weight: 700; }

/* ---------- Mobil ---------- */
@media (max-width: 760px) {
  .sect, .spec li, .linklist a, .ref { grid-template-columns: 1fr; }
  .sect { padding-bottom: 2.5rem; }
  .ref { gap: .25rem; }
  .nav ul { gap: .25rem 1.1rem; }
  .titleblock { grid-template-columns: 1fr 1fr; }
  .tb-cell:nth-child(4n) { border-right: 1px solid var(--ink); }
  .tb-cell:nth-child(2n) { border-right: 0; }
  .tb-cell:nth-last-child(-n+4) { border-bottom: 1px solid var(--ink); }
  .tb-cell:nth-last-child(-n+2) { border-bottom: 0; }
}

@media print {
  .site-header nav, .skip { display: none; }
  body { background: #fff; }
}
