/* BeMa Group · bemagroup.de (Stand 10/2026)
   Schwarz-weiß, Schriften wie die Logos: Playfair Display und Montserrat.
   Schriften lokal (SIL Open Font License 1.1), keine externen Anfragen, keine Cookies, kein JavaScript.
   CSP ohne 'unsafe-inline': keine style-Attribute; Logos inline mit fill="currentColor".
   Nach Änderungen hier _quellen/seitenbau/bauen.py ausführen (Versionsparameter im Stylesheet-Link). */

@font-face {
  font-family: 'Playfair Display';
  src: url('fonts/playfair-display-latin.woff2') format('woff2');
  font-weight: 400 900; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Playfair Display';
  src: url('fonts/playfair-display-italic-latin.woff2') format('woff2');
  font-weight: 400; font-style: italic; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Montserrat';
  src: url('fonts/montserrat-latin.woff2') format('woff2');
  font-weight: 100 900; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --tinte: #111111;        /* Tiefschwarz */
  --papier: #FFFFFF;
  --text: #2B2B2B;         /* Fließtext auf Weiß, 14,1 : 1 */
  --grau: #5E5E5E;         /* kleine Schrift auf Weiß, 6,5 : 1 */
  --linie-zart: #DADADA;
  --nacht-text: #D2D2D2;   /* Fließtext auf Schwarz, 12,6 : 1 */
  --nacht-grau: #A3A3A3;   /* kleine Schrift auf Schwarz, 7,6 : 1 */
  --nacht-linie: #3D3D3D;
  --serif: 'Playfair Display', 'Times New Roman', Georgia, serif;
  --sans: 'Montserrat', 'Helvetica Neue', Arial, sans-serif;
  --rand: clamp(20px, 5vw, 64px);
  --abstand: clamp(96px, 12vw, 168px);
  --weich: cubic-bezier(.22, .61, .36, 1);
  --dauer: .3s;
  /* Kleine Versal-Beschriftungen: eine Größe (Untergrenze 12 px), eine Sperrung */
  --versal: 12px;
  --sperrung: 0.2em;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--papier);
  color: var(--tinte);
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, p, ul, ol, figure, address { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
em { font-style: italic; }
::selection { background: var(--tinte); color: var(--papier); }
:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
.nw { white-space: nowrap; }
.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}
.huelle { width: 100%; max-width: calc(1140px + 2 * var(--rand)); margin-inline: auto; padding-inline: var(--rand); }

.icon { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

/* Überschriften: genau zwei Stufen. Abschnittstitel (alle h2) und die Begrüßung (größer). */
h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(36px, 4.8vw, 60px);
  line-height: 1.06;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
/* Abschnittstitel mit feinem Lot darüber */
.titel { text-align: center; }
.titel::before {
  content: '';
  display: block;
  width: 1px;
  height: clamp(44px, 5.5vw, 72px);
  margin: 0 auto clamp(26px, 3vw, 38px);
  background: currentColor;
}

/* Rahmen-Motiv der Logos: oben und unten durchgehend, die Seiten setzen in der Mitte aus */
.motiv { position: relative; }
.motiv::before, .motiv::after {
  content: '';
  position: absolute;
  left: var(--motiv-x, 9%);
  right: var(--motiv-x, 9%);
  height: var(--motiv-h, clamp(22px, 3vw, 34px));
  border: 1px solid currentColor;
  pointer-events: none;
}
.motiv::before { top: 0; border-bottom: 0; }
.motiv::after { bottom: 0; border-top: 0; }

/* Kopf mit Logo */
.kopfbereich {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(44px, 6.5vw, 92px) var(--rand) clamp(44px, 5.5vw, 76px);
}
.marke { line-height: 0; }
.logo-gross { width: clamp(212px, 23vw, 300px); height: auto; }
/* Zusatzzeile unter dem Logo: einzige Versalzeile mit weiterer Sperrung (wie GROUP im Logo) */
.eyebrow {
  --eyebrow-sp: 0.3em;
  margin-top: clamp(24px, 2.6vw, 36px);
  display: flex;
  align-items: center;
  gap: 20px;
  font-weight: 500;
  font-size: var(--versal);
  line-height: 1.9;
  letter-spacing: var(--eyebrow-sp);
  text-transform: uppercase;
  color: var(--grau);
}
/* Laufweite nach dem letzten Zeichen jeder Zeile ausgleichen */
.eyebrow > span { padding-left: var(--eyebrow-sp); }
.eyebrow::before, .eyebrow::after { content: ''; flex: none; width: 40px; height: 1px; background: currentColor; }
@media (max-width: 599px) {
  /* zweizeilig und schmaler als das Logo: UNTERNEHMENSGRUPPE / AUS BAMBERG */
  .eyebrow { --eyebrow-sp: var(--sperrung); line-height: 2; }
  .eyebrow .nw { display: block; }
  .eyebrow::before, .eyebrow::after { display: none; }
}

/* Gründerfoto im Passepartout und Begrüßung
   Der Rahmen liegt auf der Spaltenkante (wie Kacheln und Überschriften), das Foto sitzt innen.
   (Startseite ohne automatische Silbentrennung: Flattersatz, Markennamen mit festem Leerzeichen) */
.gruender {
  max-width: 1140px;
  margin-inline: auto;
  padding: clamp(8px, 1.25vw, 18px);
  border: 1px solid var(--tinte);
}
.gruender img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: 50% 25%; /* 4:3 beschneidet nur seitlich, 3:2 gar nicht; ab 1024 px 5:3 statt 16:9, sonst fehlen Hände und Laptopkante */
  background: #E6E6E6;
}
@media (min-width: 640px) { .gruender img { aspect-ratio: 3 / 2; } }
@media (min-width: 1024px) { .gruender img { aspect-ratio: 5 / 3; } }

.willkommen-text {
  max-width: 1140px;
  margin: clamp(68px, 9vw, 128px) auto 0;
  display: grid;
  gap: 22px;
}
.willkommen-text h2 { font-size: clamp(44px, 5.8vw, 80px); }
.lead {
  max-width: 34em;
  font-size: clamp(17px, 1.45vw, 19.5px);
  line-height: 1.8;
  color: var(--text);
  text-wrap: pretty;
}
@media (min-width: 900px) {
  .willkommen-text { grid-template-columns: 5fr 7fr; gap: clamp(48px, 6vw, 96px); align-items: start; }
  .willkommen-text h2 { margin-top: -0.12em; }
  .lead { margin-top: 0.35em; }
}

/* Unsere Unternehmen: drei Kacheln, die ganze Kachel ist der Link */
.marken { padding-top: var(--abstand); }
.kacheln {
  max-width: 1140px;
  margin: clamp(44px, 5vw, 68px) auto 0;
  display: grid;
  border: 1px solid var(--tinte);
}
.kachel {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(44px, 5vw, 64px) clamp(24px, 3vw, 44px) clamp(36px, 4vw, 48px);
  transition: background-color var(--dauer) var(--weich), color var(--dauer) var(--weich);
}
.kachel + .kachel { border-top: 1px solid var(--tinte); }
.kachel h3 { line-height: 0; }
.kachel-link { display: block; color: inherit; text-decoration: none; }
.kachel-link::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.kachel-link:focus-visible { outline: none; }
.kachel-link:focus-visible::after { outline: 2px solid currentColor; outline-offset: -10px; }
.logo-kachel { width: clamp(176px, 16vw, 210px); height: auto; }
.kachel-text {
  margin-top: 30px;
  max-width: 21em;
  font-size: 15.5px;
  line-height: 1.75;
  color: var(--grau);
  text-wrap: pretty;
  transition: color var(--dauer) var(--weich);
}
.kachel-text::before { content: ''; display: block; width: 28px; height: 1px; margin: 0 auto 26px; background: currentColor; }
.kachel-ziel {
  margin-top: auto;
  padding-top: 28px;
  font-weight: 600;
  font-size: var(--versal);
  line-height: 1.8;
  letter-spacing: var(--sperrung);
  text-transform: uppercase;
}
.kachel-ziel .pfeil {
  display: inline-block;
  vertical-align: -2px;
  width: 15px;
  height: 15px;
  margin-left: 8px;
  stroke-width: 1.6;
  transition: transform var(--dauer) var(--weich);
}
/* Umkehr auf Schwarz: mit der Maus beim Überfahren, mit der Tastatur bei sichtbarem Fokus.
   Kein :active und kein Hover auf Touch-Geräten, damit eine angetippte Kachel nach der
   Rückkehr aus dem neuen Tab nicht schwarz stehen bleibt. */
.kachel:has(.kachel-link:focus-visible) { background: var(--tinte); color: var(--papier); }
.kachel:has(.kachel-link:focus-visible) .kachel-text { color: var(--nacht-text); }
.kachel:has(.kachel-link:focus-visible) .pfeil { transform: translate(3px, -3px); }
@supports not selector(:has(a)) {
  .kachel:focus-within { background: var(--tinte); color: var(--papier); }
  .kachel:focus-within .kachel-text { color: var(--nacht-text); }
}
@media (hover: hover) and (pointer: fine) {
  .kachel:hover { background: var(--tinte); color: var(--papier); }
  .kachel:hover .kachel-text { color: var(--nacht-text); }
  .kachel:hover .pfeil { transform: translate(3px, -3px); }
}

@media (min-width: 640px) and (max-width: 959px) {
  .kachel {
    display: grid;
    grid-template-columns: 210px 1fr;
    grid-template-rows: 1fr auto auto 1fr;
    column-gap: clamp(32px, 5vw, 56px);
    align-items: center;
    justify-items: start;
    text-align: left;
    padding: 44px clamp(28px, 5vw, 52px);
  }
  .kachel h3 { grid-row: 1 / -1; }
  .kachel-text { grid-row: 2; margin-top: 0; }
  .kachel-text::before { margin: 0 0 20px; }
  .kachel-ziel { grid-row: 3; padding-top: 14px; }
  .logo-kachel { width: 200px; }
}
@media (min-width: 960px) {
  .kacheln { grid-template-columns: repeat(3, 1fr); }
  .kachel + .kachel { border-top: 0; border-left: 1px solid var(--tinte); }
}
@media (min-width: 960px) and (max-width: 1199px) {
  .kachel { padding-inline: 20px; }
}

/* Geschichte: der eine schwarze Abschnitt */
.geschichte {
  margin-top: var(--abstand);
  padding: var(--abstand) 0;
  background: var(--tinte);
  color: var(--papier);
}
.geschichte ::selection { background: var(--papier); color: var(--tinte); }
.kapitel {
  max-width: 1140px;
  margin: clamp(52px, 6vw, 84px) auto 0;
  display: grid;
  gap: 48px;
}
.kapitel li { border-top: 1px solid var(--nacht-linie); padding-top: 30px; }
.kapitel-nr {
  display: block;
  font-family: var(--serif);
  font-style: italic;
  font-size: 21px;
  line-height: 1;
  color: var(--nacht-grau);
}
.kapitel h3 {
  margin-top: 20px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(25px, 2.3vw, 29px);
  line-height: 1.2;
  letter-spacing: -0.005em;
}
.kapitel p {
  margin-top: 16px;
  font-size: 16.5px;
  line-height: 1.8;
  color: var(--nacht-text);
  text-wrap: pretty;
}
@media (max-width: 1119px) { .kapitel { max-width: 620px; } }
@media (min-width: 1120px) { .kapitel { grid-template-columns: repeat(3, 1fr); gap: clamp(40px, 4.5vw, 64px); } }

/* Unterschrift der beiden im Rahmen-Motiv */
.schluss {
  --motiv-x: 0%;
  max-width: 520px;
  margin: clamp(84px, 10vw, 140px) auto 0;
  padding: clamp(46px, 5.5vw, 64px) 24px;
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(32px, 3.7vw, 46px);
  line-height: 1.25;
  text-wrap: balance;
}

/* Instagram: typografische Zeile ohne Kästen und Icons */
.instagram { padding-top: var(--abstand); }
.einleitung {
  max-width: 33em;
  margin: 26px auto 0;
  text-align: center;
  color: var(--text);
  text-wrap: pretty;
}
.konten {
  max-width: 1140px;
  margin: clamp(36px, 4.5vw, 60px) auto 0;
  display: grid;
  justify-items: center;
}
.konten li { display: flex; flex-direction: column; align-items: center; }
/* feine senkrechte Trennlinie zwischen den Konten */
.konten li + li::before { content: ''; width: 1px; height: 32px; margin: 6px 0; background: var(--linie-zart); }
.konto {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 10px 16px;
  text-align: center;
  text-decoration: none;
}
.konto-name {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  line-height: 1.3;
  text-decoration: underline 1px;
  text-decoration-color: transparent;
  text-underline-offset: 6px;
  transition: text-decoration-color var(--dauer) var(--weich);
}
.konto-zusatz {
  margin-top: 6px;
  font-weight: 500;
  font-size: var(--versal);
  line-height: 1.5;
  letter-spacing: var(--sperrung);
  text-transform: uppercase;
  color: var(--grau);
}
.konto:focus-visible .konto-name { text-decoration-color: currentColor; }
@media (hover: hover) and (pointer: fine) {
  .konto:hover .konto-name { text-decoration-color: currentColor; }
}
@media (min-width: 760px) {
  .konten { grid-template-columns: repeat(3, 1fr); justify-items: stretch; }
  /* Namen stehen auf einer Linie, auch wenn ein Zusatz zweizeilig umbricht (Tablet) */
  .konten li { position: relative; justify-content: flex-start; }
  .konto-zusatz { text-wrap: balance; }
  .konten li + li::before { position: absolute; left: 0; top: 50%; height: 48px; margin: -24px 0 0; }
  .konto { padding: 12px 20px; }
  .konto-name { font-size: clamp(22px, 2.2vw, 26px); }
}

/* Kontakt im Logo-Rahmen */
.kontakt { padding-top: var(--abstand); padding-bottom: var(--abstand); }
/* wie im Logo: Linie oben mit kurzen Seiten, offene Mitte mit der Überschrift,
   darunter setzen die Seiten wieder an und schließen unten mit der Anschrift als „Tagline“ */
.kontakt-rahmen {
  --oben: clamp(64px, 8vw, 104px);
  position: relative;
  max-width: 880px;
  margin-inline: auto;
  padding-top: var(--oben);
  border-top: 1px solid var(--tinte);
  text-align: center;
}
.kontakt-rahmen::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: calc(var(--oben) - clamp(26px, 3vw, 36px));
  border-left: 1px solid var(--tinte);
  border-right: 1px solid var(--tinte);
  pointer-events: none;
}
.kontakt-rahmen .einleitung { margin-top: 22px; padding-inline: 12px; }
.kontakt-unten {
  margin-top: clamp(26px, 3vw, 36px);
  padding: clamp(32px, 4vw, 48px) clamp(16px, 5vw, 56px) clamp(34px, 4.4vw, 50px);
  border: 1px solid var(--tinte);
  border-top: 0;
}
.aktionen {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}
.knopf {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 56px;
  max-width: 100%;
  padding: 0 28px;
  border: 1px solid var(--tinte);
  background: var(--tinte);
  color: var(--papier);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-decoration: none;
  transition: background-color var(--dauer) var(--weich), color var(--dauer) var(--weich);
}
.knopf svg { flex: none; width: 18px; height: 18px; }
.knopf-hell { background: var(--papier); color: var(--tinte); }
.knopf:focus-visible { outline-color: var(--tinte); }
@media (hover: hover) and (pointer: fine) {
  .knopf:hover { background: var(--papier); color: var(--tinte); }
  .knopf-hell:hover { background: var(--tinte); color: var(--papier); }
}
.anschrift {
  margin-top: 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-style: normal;
  font-weight: 500;
  font-size: var(--versal);
  line-height: 2.1;
  letter-spacing: var(--sperrung);
  text-transform: uppercase;
  color: var(--grau);
}
@media (min-width: 640px) {
  .anschrift { flex-direction: row; justify-content: center; flex-wrap: wrap; }
  .anschrift span + span::before { content: '·'; margin: 0 0.9em 0 0.7em; }
}

/* Fußzeile */
.fuss { border-top: 1px solid var(--linie-zart); }
.fuss-innen {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 14px;
  padding-bottom: 18px;
  font-weight: 500;
  font-size: var(--versal);
  letter-spacing: var(--sperrung);
  text-transform: uppercase;
  color: var(--grau);
}
.fuss-nav { display: flex; gap: 0 28px; }
.fuss .copy, .fuss a { display: inline-flex; align-items: center; min-height: 44px; }
.fuss a { text-decoration: none; text-decoration-thickness: 1px; text-underline-offset: 5px; }
.fuss a:focus-visible { color: var(--tinte); text-decoration: underline; }
@media (hover: hover) and (pointer: fine) {
  .fuss a:hover { color: var(--tinte); text-decoration: underline; }
}
.fuss a[aria-current="page"] { color: var(--tinte); }
@media (min-width: 640px) { .fuss-innen { flex-direction: row; justify-content: space-between; } }

/* Rechtstexte (Impressum, Datenschutz) und Fehlerseite */
.recht {
  max-width: calc(740px + 2 * var(--rand));
  margin-inline: auto;
  padding: clamp(44px, 6.5vw, 84px) var(--rand) clamp(72px, 9vw, 112px);
  overflow-wrap: break-word;
}
.recht .kopf { display: flex; flex-direction: column; align-items: center; text-align: center; }
.logo-link { display: inline-block; line-height: 0; color: var(--tinte); }
.logo-klein { width: clamp(150px, 36vw, 188px); height: auto; }
.recht h1 {
  margin-top: clamp(34px, 4vw, 46px);
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(38px, 5.6vw, 56px);
  line-height: 1.06;
  letter-spacing: -0.015em;
  text-align: center;
  text-wrap: balance;
}
.trenner { width: 1px; height: 48px; margin: 30px auto 4px; background: var(--tinte); }
.recht h2 {
  margin-top: 46px;
  font-size: clamp(23px, 3vw, 27px);
  line-height: 1.25;
  letter-spacing: -0.005em;
  text-wrap: pretty;
}
.recht h3 {
  margin-top: 28px;
  font-size: var(--versal);
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: var(--sperrung);
  text-transform: uppercase;
}
.recht p, .recht ul, .recht address {
  margin-top: 12px;
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  font-style: normal;
}
.recht p, .recht li { -webkit-hyphens: auto; hyphens: auto; hyphenate-limit-chars: 10 4 4; }
.recht ul { padding-left: 1.15em; list-style: square; }
.recht li::marker { color: var(--grau); font-size: 0.8em; }
.recht li + li { margin-top: 8px; }
/* Adressen in Links nie mit Silbentrennstrich umbrechen */
.recht a { -webkit-hyphens: manual; hyphens: manual; text-decoration-thickness: 1px; text-underline-offset: 3px; overflow-wrap: anywhere; }
/* Firmen- und Markennamen nicht trennen („BeMa Apart-ments“) */
.recht strong { font-weight: 600; color: var(--tinte); -webkit-hyphens: manual; hyphens: manual; }
.recht .stand { margin-top: 48px; font-size: 13px; color: var(--grau); }
.recht .hinweis { margin: 40px auto 0; max-width: 30em; text-align: center; -webkit-hyphens: manual; hyphens: manual; text-wrap: pretty; }
.zurueck {
  display: flex;
  align-items: flex-end;
  width: fit-content;
  min-height: 44px;
  margin: 44px auto 0;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--tinte);
  font-weight: 500;
  font-size: var(--versal);
  letter-spacing: var(--sperrung);
  text-transform: uppercase;
  text-decoration: none;
  color: var(--tinte);
}
@media (hover: hover) and (pointer: fine) {
  .recht a:hover { text-decoration-thickness: 2px; }
  .zurueck:hover { border-bottom-width: 2px; padding-bottom: 3px; }
}

@media (max-width: 599px) {
  .aktionen { flex-direction: column; align-items: stretch; max-width: 300px; margin-inline: auto; }
  .kontakt-rahmen .einleitung { padding-inline: 0; }
  /* mobil etwas dichtere Zeilen */
  .lead { line-height: 1.65; }
  .kapitel p { line-height: 1.75; }
  .einleitung { line-height: 1.7; }
}

/* Sehr schmale Handys */
@media (max-width: 359px) {
  h2 { font-size: 32px; }
  .knopf { padding: 0 14px; gap: 10px; font-size: 13.5px; letter-spacing: 0.03em; }
  .kachel { padding-inline: 18px; }
  .konto { padding-inline: 8px; }
  .konto-name { font-size: 21px; }
}

/* Weniger Bewegung */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .kachel .pfeil { transform: none !important; }
}
