/* HANF Advanced Fire Engineering -- ein Stylesheet fuer alle Seiten.
   Gestaltung nach dem Figma-Entwurf der Agentur (Oktober 2026): helle Seite,
   Rot nur als Akzent, schwarze 1-px-Linien zwischen den Abschnitten, Karten
   auf #f5f5f5 mit 5 px Radius, Pillen-Buttons, Wasserzeichen-A.
   Farben und Schriften stehen nur hier in :root; Seiten setzen keine
   Inline-Styles, weil die Content-Security-Policy sie nicht erlaubt. */

/* Schriften liegen im Repo (static/fonts), es geht kein Request an Dritte.
   Nur der Latin-Schnitt: Deutsch braucht nichts darueber hinaus. */
@font-face {
  font-family: "Inter Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url("/fonts/inter-latin-wght-normal.woff2") format("woff2-variations");
  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;
}

/* Der Entwurf setzt "Nimbus Sans Extended Bold" (lizenzpflichtig). Archivo
   in 125 % Breite kommt ihr sehr nah. Nachruesten: @font-face fuer
   "Nimbus Sans Extended" ergaenzen -- --font-display nennt sie schon zuerst. */
@font-face {
  font-family: "Archivo Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  src: url("/fonts/archivo-latin-wdth-normal.woff2") format("woff2-variations");
  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;
}

/* Systemschrift mit angepassten Metriken, solange die Webfont laedt:
   so springt der Text beim Tausch nicht (kein Layout-Shift). */
@font-face {
  font-family: "Inter Fallback";
  src: local("Arial"), local("Helvetica"), local("Liberation Sans");
  ascent-override: 90.49%;
  descent-override: 22.56%;
  line-gap-override: 0%;
  size-adjust: 107.06%;
}

@font-face {
  font-family: "Archivo Fallback";
  src: local("Arial"), local("Helvetica"), local("Liberation Sans");
  ascent-override: 76%;
  descent-override: 18%;
  line-gap-override: 0%;
  size-adjust: 121%;
}

:root {
  /* Farbvariablen aus der Figma-Datei (HANF Red, Super Light Grey, ...). */
  --black: #000000;
  --white: #ffffff;
  --red: #eb1d25;
  /* Weisse Schrift auf #eb1d25 kommt nur auf 4,43:1; Flaechen mit weissem
     Text nehmen diesen kaum sichtbar dunkleren Ton (4,54:1). */
  --red-surface: #e81c24;
  /* Rote Schrift auf Weiss ebenso: #d1141c erreicht 5,1:1. */
  --red-text: #d1141c;
  --surface: #f5f5f5;
  --line: #000000;
  --grey: #cccccc;
  --grey-dark: #9c9c9c;
  /* Figma setzt die Kontaktflaeche auf #9c9c9c; weisse Schrift darauf ist
     mit 2,4:1 unlesbar. #767676 stammt ebenfalls aus der Figma-Palette und
     erreicht 4,5:1. */
  --grey-text: #767676;
  --text-muted: #4d4d4d;

  --font-body: "Inter Variable", "Inter Fallback", system-ui, sans-serif;
  --font-display: "Nimbus Sans Extended", "Archivo Variable", "Archivo Fallback", sans-serif;

  --header-height: 132px;
  --gutter: 40px;
  --wrap: 1648px;
  --section-gap: 120px;
}

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

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

body {
  margin: 0;
  background: var(--white);
  color: var(--black);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.667;
  -webkit-font-smoothing: antialiased;
}

img,
svg {
  display: block;
  max-width: 100%;
  /* Ohne height:auto bekommt ein Bild mit width/height-Attributen eine feste Hoehe. */
  height: auto;
}

a {
  color: inherit;
}

a:hover {
  color: var(--red-text);
}

h1,
h2,
h3,
p,
dl,
dd {
  margin: 0;
}

[hidden] {
  display: none !important;
}

/* Fokus: roter Ring auf hell, weisser auf dunkel. */
:focus-visible {
  outline: 3px solid var(--red-text);
  outline-offset: 3px;
  border-radius: 4px;
}

.contact-section :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--white);
}

/* Anker unter dem festen Header nicht verstecken. */
section[id] {
  scroll-margin-top: var(--header-height);
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 100;
  padding: 12px 18px;
  border-radius: 100px;
  background: var(--black);
  color: var(--white);
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
}

.wrap {
  max-width: calc(var(--wrap) + 2 * var(--gutter));
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.disp {
  font-family: var(--font-display);
  font-stretch: 125%;
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* Figma: Eyebrow ist Inter Bold 18/30 in Rot, keine Versalien. */
.eyebrow {
  color: var(--red-text);
  font-size: 18px;
  font-weight: 700;
  line-height: 30px;
}

.section-title {
  font-size: clamp(34px, 3.5vw, 60px);
  line-height: 1.2;
}

/* Trennlinie zwischen den Abschnitten: 1 px schwarz ueber die Inhaltsbreite,
   mit dem Abstand des Entwurfs darueber. */
.rule {
  margin: var(--section-gap) 0 0;
  border: 0;
  border-top: 1px solid var(--line);
}

/* Wasserzeichen: das "A" aus dem Logo als Maske, die Farbe kommt aus dem
   jeweiligen Abschnitt (hell auf Weiss, leicht aufgehellt auf Grau). */
.watermark {
  position: absolute;
  z-index: 0;
  aspect-ratio: 1174 / 831;
  background-color: var(--surface);
  pointer-events: none;
  -webkit-mask: url("/assets/hanf-a-watermark.svg") no-repeat center / contain;
  mask: url("/assets/hanf-a-watermark.svg") no-repeat center / contain;
}

/* Buttons: Pillen, 60 px hoch, Inter 18 (Figma CTA / CTA Red). */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 60px;
  padding: 0 30px;
  border: 0;
  border-radius: 100px;
  background: var(--surface);
  color: var(--black);
  font: inherit;
  font-size: 18px;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.btn:hover {
  background: #e5e5e5;
  color: var(--black);
}

.btn-primary {
  background: var(--red-surface);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--red-text);
  color: var(--white);
}

.btn[disabled] {
  cursor: progress;
  opacity: 0.7;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 40px;
}

/* Header: weiss, bleibt oben stehen; Logo links, roter Zusatz in der Mitte,
   zweireihige Navigation rechts hinter einer senkrechten Linie. */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  color: var(--black);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  min-height: var(--header-height);
}

.brand {
  flex: 0 0 auto;
  text-decoration: none;
}

.brand img {
  width: 270px;
}

.brand-sub {
  flex: 1 1 auto;
  color: var(--red-text);
  font-size: 18px;
  font-weight: 700;
  text-align: center;
}

.site-nav {
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: repeat(2, auto);
  gap: 12px 60px;
  align-content: center;
  min-height: 112px;
  padding-left: 80px;
  border-left: 1px solid var(--line);
  font-size: 18px;
}

.site-nav a,
.lang-switch {
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  color: var(--black);
  text-decoration: none;
}

.site-nav a:hover,
.lang-switch:hover {
  border-bottom-color: var(--black);
  color: var(--black);
}

/* Der Sprachumschalter ist das sechste Feld der Navigation (Wunsch Thomas).
   Die Aktionen rechts gibt es nur mobil: dort ersetzt der Kontakt-Button die
   ausgeblendete Navigation. */
.lang-switch {
  font-size: 18px;
}

.header-actions {
  display: none;
}

/* Hero: links Text, rechts das Wasserzeichen an der Stelle, die der Entwurf
   fuer ein spaeteres Bild frei laesst. */
.hero {
  position: relative;
  overflow: hidden;
  padding-top: 90px;
}

.hero-grid {
  display: grid;
  /* Rechts hoechstens gut ein Drittel: sonst bricht die Ueberschrift auf
     mittleren Bildschirmen in sechs Zeilen. */
  grid-template-columns: minmax(0, 1fr) minmax(0, 36%);
  gap: 40px 80px;
  align-items: center;
}

.hero h1 {
  max-width: 980px;
  margin-top: 30px;
  font-size: clamp(40px, 4.6vw, 80px);
  line-height: 1;
}

.hero-lead {
  max-width: 815px;
  margin-top: 17px;
}

/* Im Hero in Markenrot, nicht als blasses Wasserzeichen: Wunsch von Thomas. */
.hero-mark {
  position: relative;
  width: 100%;
  background-color: var(--red);
}

/* .card-grid setzt margin: 0 und steht weiter unten; deshalb mit Abschnitt. */
.hero .focus-grid {
  margin-top: var(--section-gap);
}

/* Abschnitte: Titel links, Einleitung rechts, Inhalt 80 px darunter. Die
   Einleitung ist ein Satz und soll in einer Zeile stehen; 760 px reichen fuer
   den laengsten (Karriere). */
.section {
  padding-top: var(--section-gap);
}

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 760px);
  gap: 17px 60px;
  align-items: start;
}

.section-head p + p {
  margin-top: 16px;
}

.lead-strong {
  font-weight: 700;
}

/* Spezifischer als .card-grid (margin: 0), das weiter unten steht. */
.section .section-body {
  margin-top: 80px;
}

/* Karten wie im Entwurf: #f5f5f5, 5 px Radius, roter Titel, Linie, Text. */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.card {
  display: flex;
  flex-direction: column;
  padding: 20px 20px 40px;
  border-radius: 5px;
  background: var(--surface);
}

/* Platz des Fotos im Entwurf: solange keine Bilder da sind, das Symbol. */
.card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  margin-bottom: 25px;
  border-radius: 5px;
  background: var(--white);
  color: var(--red);
}

/* Foto oben in der Karte, wie im Entwurf (417 x 230): ersetzt das Symbol,
   sobald eigene Bilder da sind (README, "Fotos und Grafiken einbauen"). */
.card-image {
  width: 100%;
  aspect-ratio: 417 / 230;
  margin-bottom: 25px;
  border-radius: 5px;
  object-fit: cover;
}

/* Team: Portraets im Hochformat; freigestellte Fotos liegen auf der grauen
   Karte wie in Ueber uns. Mit auto-fill bleiben die Karten auch bei nur
   einer oder zwei Personen in Spaltenbreite, statt sich ueber die ganze
   Zeile zu dehnen. */
.team-grid {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
}

.team-photo {
  width: 100%;
  aspect-ratio: 3 / 4;
  margin-bottom: 25px;
  border-radius: 5px;
  object-fit: cover;
  object-position: center top;
}

/* Fuenf Leistungen: bei voller Breite in einer Reihe, sonst 3 + 2 statt 4 + 1. */
.services-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.card h2,
.card h3 {
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
  color: var(--red-text);
  font-family: var(--font-body);
  font-size: 18px;
  font-stretch: normal;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.3;
}

.card h3 a {
  text-decoration: none;
}

.card h3 a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.card p {
  margin-top: 20px;
  hyphens: auto;
}

.card p + p {
  margin-top: 12px;
}

/* Der graue Standard-Button verschwindet auf der grauen Karte; dort weiss. */
.card .btn:not(.btn-primary) {
  background: var(--white);
}

.card .btn:not(.btn-primary):hover {
  background: #e5e5e5;
}

/* Ueber uns: Portraet links mit Bildunterschrift, Text rechts, grosses
   Wasserzeichen dahinter wie im Entwurf. */
.about .wrap {
  position: relative;
}

.about-mark {
  top: 0;
  right: var(--gutter);
  /* 58 % statt 70 %: mit 70 % reichte das A fast bis an die Trennlinie. */
  width: min(1174px, 58%);
}

.about-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 379px) minmax(0, 1fr);
  gap: 40px 120px;
  align-items: start;
}

.portrait {
  overflow: hidden;
  aspect-ratio: 379 / 552;
  border-radius: 5px;
  background: var(--surface);
}

/* Freigestelltes Portraet auf der grauen Flaeche; oben ausrichten, damit
   der Kopf nie beschnitten wird, unten darf der Arm wegfallen. */
.portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.portrait-caption {
  margin-top: 13px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
  font-size: 14px;
  line-height: 24px;
}

.portrait-caption span {
  color: var(--grey-dark);
}

.about-intro {
  max-width: 700px;
  margin-top: 17px;
}

.facts {
  display: grid;
  /* 200 px je Kennzahl, damit "800+ MW" nicht umbricht; mobil untereinander.
     Zwei Kennzahlen mit viel Luft dazwischen (Wunsch Thomas). */
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px 80px;
  max-width: 700px;
  margin-top: 40px;
}

.fact {
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.fact dt {
  font-size: 36px;
  line-height: 1.1;
}

.fact dd {
  margin-top: 6px;
  color: var(--grey-dark);
  font-size: 14px;
  line-height: 24px;
}

.vita-toggle {
  margin-top: 40px;
}

.vita-toggle svg {
  transition: transform 0.2s ease;
}

.vita-toggle[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

.vita {
  margin-top: 40px;
  column-width: 380px;
  column-gap: 60px;
}

.vita p {
  margin: 0 0 20px;
  break-inside: avoid;
}

/* Karriere: Stellen als Karten, Buttons unten buendig. */
.job-meta {
  color: var(--text-muted);
}

.job-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: auto;
  padding-top: 30px;
}

/* Kontakt: dunkelgraue Flaeche ueber die volle Breite, Telefon und E-Mail
   gross in der Display-Schrift, rechts das Formular. */
.contact-section {
  position: relative;
  overflow: hidden;
  margin-top: var(--section-gap);
  padding: var(--section-gap) 0;
  background: var(--grey-text);
  color: var(--white);
}

/* Wie im Entwurf rechts unten hinter dem Inhalt, aber so weit innen, dass
   das A ganz zu sehen ist: beim ersten Stand fehlte der untere Teil. */
.contact-mark {
  left: 50%;
  bottom: 18%;
  width: min(44%, 720px);
  background-color: rgba(255, 255, 255, 0.16);
  transform: translateX(-50%);
}

.contact {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 620px);
  gap: 60px 120px;
  align-items: start;
}

.contact-section a:hover {
  color: var(--white);
}

/* Die grosse Telefonnummer und E-Mail richten sich nach der Spaltenbreite,
   sonst bricht die Adresse auf mittleren Bildschirmen mitten im Wort um. */
.contact-info {
  container-type: inline-size;
}

.contact-address {
  margin-top: 8px;
  font-size: 16px;
  font-weight: 500;
  line-height: 30px;
}

.contact-big {
  margin-top: 60px;
}

.contact-big + .contact-big {
  margin-top: 40px;
}

.contact-label {
  font-size: 16px;
  font-weight: 500;
  line-height: 30px;
}

.contact-big a {
  display: block;
  margin-top: 20px;
  font-size: clamp(22px, 6.2cqw, 60px);
  letter-spacing: 0.01em;
  line-height: 1.1;
  overflow-wrap: anywhere;
  text-decoration: none;
}

.contact-big a:hover {
  text-decoration: underline;
  text-underline-offset: 8px;
}

.contact-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  align-content: start;
  min-width: 0;
}

.form-intro,
.field-wide,
.form-consent,
.form-actions,
.form-status {
  grid-column: 1 / -1;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  font-size: 16px;
  font-weight: 500;
}

.field input,
.field textarea {
  width: 100%;
  min-height: 56px;
  padding: 0 16px;
  border: 1px solid var(--grey);
  border-radius: 5px;
  background: var(--white);
  color: var(--black);
  font: inherit;
  font-size: 18px;
  font-weight: 400;
}

.field textarea {
  padding: 14px 16px;
  resize: vertical;
}

.field input:focus-visible,
.field textarea:focus-visible {
  outline-offset: 1px;
  border-radius: 5px;
}

.field [aria-invalid="true"],
.form-consent [aria-invalid="true"] {
  border: 2px solid var(--red);
}

/* Rot ist auf dem Grau nicht lesbar; Fehler stehen deshalb weiss und fett,
   das Feld selbst bekommt den roten Rand. */
.field-error {
  font-size: 14px;
  font-weight: 600;
}

.optional {
  font-weight: 400;
  opacity: 0.85;
}

.form-consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14px;
  line-height: 1.5;
}

.form-consent input {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  margin: 1px 0 0;
  accent-color: var(--black);
}

.form-consent .field-error {
  display: block;
  margin-top: 4px;
}

/* Honeypot: fuer Menschen unsichtbar, fuer Screenreader ausgeblendet. */
.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-status {
  padding: 16px 20px;
  border-radius: 5px;
  background: var(--white);
  color: var(--black);
  font-size: 16px;
}

.form-status:empty {
  display: none;
}

.form-status.is-error {
  border: 2px solid var(--red);
}

.form-status a {
  text-decoration: underline;
}

/* Footer: schwarz, Logo oben, Navigation und Rechtliches in Grau unten. */
.site-footer {
  padding: 50px 0 40px;
  background: var(--black);
  color: var(--grey-text);
}

.footer-top {
  display: flex;
  flex-wrap: wrap;
  /* Zusatz steht wie im Kopf 160 px rechts vom Logo, nicht am rechten Rand. */
  gap: 24px 160px;
  align-items: center;
}

.footer-top img {
  width: 270px;
}

.footer-top span {
  color: var(--white);
  font-size: 16px;
  font-weight: 700;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  align-items: flex-end;
  justify-content: space-between;
  margin-top: 120px;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  align-items: center;
}

.footer-nav ul {
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: repeat(2, auto);
  gap: 12px 60px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-legal {
  display: grid;
  gap: 12px;
  padding-left: 40px;
  border-left: 1px solid var(--grey-text);
}

.site-footer a {
  color: var(--grey-text);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Stellenseiten: gleicher Aufbau wie die Startseite, Fakten als Chips. */
.job-hero {
  padding-top: 90px;
}

.job-hero .eyebrow a {
  text-decoration: none;
}

.job-hero h1 {
  max-width: 1100px;
  margin-top: 30px;
  font-size: clamp(36px, 4.6vw, 80px);
  line-height: 1;
}

.job-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 30px 0 0;
  padding: 0;
  list-style: none;
}

.job-facts li {
  padding: 8px 18px;
  border-radius: 100px;
  background: var(--surface);
  font-size: 16px;
}

.job-lead {
  max-width: 815px;
  margin-top: 30px;
}

/* Hoechstens zwei Spalten: bei vier Bloecken sonst ein einzelner Block in
   der zweiten Reihe mit viel Leerraum daneben. */
.job-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 560px), 1fr));
  gap: 60px 120px;
}

.job-block h2 {
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
  color: var(--red-text);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
}

.job-block ul {
  margin: 20px 0 0;
  padding-left: 22px;
}

.job-block li + li {
  margin-top: 10px;
}

.job-block li::marker {
  color: var(--red-text);
}

.apply-card {
  display: flex;
  flex-wrap: wrap;
  gap: 24px 40px;
  align-items: center;
  justify-content: space-between;
  margin: var(--section-gap) 0;
  padding: 40px;
  border-radius: 5px;
  background: var(--surface);
}

.apply-card > div {
  flex: 1 1 520px;
  min-width: 0;
}

.apply-card h2 {
  margin-top: 12px;
  font-size: clamp(24px, 2.6vw, 36px);
  line-height: 1.15;
}

.apply-card p {
  margin-top: 12px;
}

/* Rechtsseiten und 404: hell, schmale Textspalte. */
.legal {
  padding: 90px 0 var(--section-gap);
}

.legal .wrap {
  max-width: calc(815px + 2 * var(--gutter));
}

.legal h1 {
  font-size: clamp(34px, 3.5vw, 60px);
  line-height: 1.2;
}

.legal h2 {
  margin: 40px 0 12px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
}

.legal h3 {
  margin: 24px 0 8px;
  font-size: 18px;
  font-weight: 600;
}

.legal p,
.legal ul {
  margin: 0 0 16px;
}

.legal ul {
  padding-left: 22px;
}

.legal .lead {
  margin-top: 16px;
  color: var(--text-muted);
}

/* Nicht fuer Buttons: sonst steht auf der 404-Seite roter Text auf rotem Grund. */
/* Rechtstexte von IT-Recht Kanzlei: der geladene Text bringt eine eigene h1
   mit, die Seite hat schon eine. Die Stand-Zeile am Ende kommt mit
   Inline-Styles, die die CSP ignoriert; sie bekommt hier ihren Platz. */
.legal .itrk-legaltext h1 {
  display: none;
}
.legal #itkanzlei_txt_copyright {
  margin-top: 48px;
  font-size: 14px;
  color: var(--grey-text);
}

.legal a:not(.btn) {
  color: var(--red-text);
}

.legal .btn {
  margin-top: 24px;
}

@media (max-width: 1500px) {
  .services-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1280px) {
  .brand-sub {
    display: none;
  }

  /* Zweispaltig bleibt der linken Spalte unter 1200 px zu wenig Platz fuer
     die grosse E-Mail-Adresse. */
  .contact {
    grid-template-columns: minmax(0, 1fr);
  }

  .site-nav {
    gap: 10px 40px;
    padding-left: 48px;
  }
}

@media (max-width: 960px) {
  :root {
    --header-height: 88px;
    --gutter: 28px;
    --section-gap: 88px;
  }

  /* Mobil: Navigation ausblenden, nur der Sprachumschalter bleibt und rueckt
     mit dem Kontakt-Button nach rechts. */
  .site-nav {
    display: block;
    min-height: 0;
    margin-left: auto;
    padding-left: 0;
    border-left: 0;
  }

  .site-nav a:not(.lang-switch) {
    display: none;
  }

  .header-actions {
    display: flex;
    align-items: center;
    margin-left: 24px;
  }

  .btn-header {
    display: inline-flex;
    min-height: 48px;
    padding: 0 22px;
    font-size: 16px;
  }

  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  /* Das rote A bleibt mobil als Markenzeichen, klein und rechts wie frueher. */
  .hero-mark {
    width: 150px;
    justify-self: end;
    margin-top: 8px;
  }

  .section-head,
  .about-grid,
  .contact {
    grid-template-columns: minmax(0, 1fr);
  }

  .services-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  /* Mobil ist der Block sehr hoch; 18 % von unten laegen hinter dem
     Nachrichtenfeld. Unten hinter dem Button bleibt das A sichtbar. */
  .contact-mark {
    bottom: 40px;
    width: 60%;
  }

  .section .section-body {
    margin-top: 48px;
  }

  .about-mark {
    width: 90%;
    right: 0;
  }

  .portrait {
    max-width: 379px;
  }

  .footer-bottom {
    margin-top: 72px;
  }
}

@media (max-width: 760px) {
  :root {
    --gutter: 20px;
    --header-height: 72px;
    --section-gap: 72px;
  }

  body {
    font-size: 16px;
    line-height: 1.6;
  }

  .brand img,
  .footer-top img {
    width: 150px;
  }

  .hero {
    padding-top: 48px;
  }

  .hero h1 {
    margin-top: 20px;
  }

  .btn {
    min-height: 52px;
    padding: 0 24px;
    font-size: 16px;
  }

  .card {
    padding: 20px 20px 28px;
  }

  .services-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .contact-section {
    padding: var(--section-gap) 0;
  }

  .contact-big {
    margin-top: 40px;
  }

  .contact-big a {
    font-size: clamp(20px, 6.2cqw, 32px);
  }

  .apply-card {
    padding: 28px 24px;
  }

  .footer-nav ul {
    gap: 10px 32px;
  }

  .footer-legal {
    padding-left: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
