/* K-Consulting & Management – site styles.
   Desktop values match the approved 1440 px design (docs/reference-desktop-1440.png).
   Breakpoints: 1279 px (text-over-image softening), 999 px (nav collapses), 899 px (stacked layout). */

:root {
  --blue: #156082;
  --navy: #042433;
  --black: #000000;
  --ink: #1D1D1F;
  --nav-ink: #171A20;
  --text-sub: #424245;
  --text-desc: #5E5E5E;
  --text-footer: #6E6E73;
  --text-caption: #767676;
  --line: #D2D2D7;
  --bg-grey: #F5F5F7;
  --white: #FFFFFF;

  --font-head: 'Archivo Narrow', 'Arial Narrow', sans-serif;
  --font-body: Inter, Arial, sans-serif;

  --header-h: 72px;
  --gutter: 32px;
  --wide: 1320px;
  --content: 1180px;
  --visual-h: min(900px, 62.5vw);
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-body);
}
img { max-width: 100%; }
picture { display: contents; }
a { color: var(--blue); text-decoration: none; }
.nowrap { white-space: nowrap; }
a:hover { color: var(--navy); }
h1, h2, h3, p { margin: 0; }
section[id] { scroll-margin-top: var(--header-h); }

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 100;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--navy);
  color: var(--white);
  font-size: 15px;
  font-weight: 500;
}
.skip-link:focus { top: 12px; color: var(--white); }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Shared type ---------- */

.overline {
  font-family: var(--font-head);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue);
}
.head {
  font-family: var(--font-head);
  font-weight: 600;
  color: var(--black);
  /* spread words evenly over the lines – no single word left alone on the last line */
  text-wrap: balance;
}
.head__line { display: block; }

/* ---------- Header / navigation ---------- */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.72);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}
.nav {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 var(--gutter);
  min-height: var(--header-h);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
}
.nav__logo { display: flex; align-items: center; }
.nav__logo img { display: block; height: 44px; width: auto; }
.nav__links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px 4px;
  font-family: var(--font-head);
  font-size: 17px;
  font-weight: 500;
}
.nav__lang {
  display: flex;
  align-items: center;
  font-family: var(--font-head);
  font-size: 15px;
  font-weight: 500;
  color: var(--text-sub);
}
.nav__lang .tab-light {
  padding: 9px 9px;
  color: var(--text-sub);
}
.nav__lang .tab-light.is-current { color: var(--nav-ink); font-weight: 600; }
.nav__lang-sep { color: var(--line); }
.site-footer__lang a.is-current { color: var(--ink); font-weight: 600; }
.nav__toggle { display: none; }

.tab-light {
  color: var(--nav-ink);
  padding: 9px 15px;
  border-radius: 9px;
  transition: background-color .3s ease;
}
.tab-light:hover,
.tab-light.is-active {
  color: var(--nav-ink);
  background-color: rgba(23, 26, 32, 0.07);
}
/* Dark variant (not used by default): background rgba(0,0,0,0.88) + logo-white */
.tab-dark {
  color: var(--white);
  padding: 9px 15px;
  border-radius: 9px;
  transition: background-color .3s ease;
}
.tab-dark:hover,
.tab-dark.is-active {
  color: var(--white);
  background-color: rgba(255, 255, 255, 0.16);
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  width: 100%;
  height: max(var(--visual-h), 100svh);
  overflow: hidden;
  background: #F2F2F7;
}
.hero__img,
.segment__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: right center;
}
.hero__copy {
  position: relative;
  height: 100%;
  max-width: var(--wide);
  margin: 0 auto;
  padding: var(--header-h) var(--gutter) 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.hero__title {
  font-size: clamp(44px, 6vw, 80px);
  line-height: 1.02;
  letter-spacing: -0.005em;
  max-width: 720px;
}
.hero__sub {
  margin-top: 26px;
  font-size: clamp(18px, 1.6vw, 21px);
  line-height: 1.45;
  max-width: 560px;
  color: var(--text-sub);
}
.hero__links {
  margin-top: 36px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 32px;
  font-size: 17px;
  font-weight: 500;
}

/* ---------- Segments (Providers, Devices, Investors, Public sector) ---------- */

.segment { background: var(--white); padding-top: 120px; }
.segment--first { padding-top: 0; }

.segment__visual {
  position: relative;
  width: 100%;
  height: var(--visual-h);
  overflow: hidden;
}
.segment--providers .segment__visual { background: #FAF9F7; }
.segment--devices .segment__visual { background: #FAFAFA; }
.segment--investors .segment__visual,
.segment--public .segment__visual { background: #FAFBFC; }

/* Soft transitions: full-bleed images fade into the white page instead of ending in a hard edge.
   Eased stops avoid visible banding. The overlay sits above the image, below the copy (DOM order). */
:root {
  --fade: clamp(64px, 10vw, 160px);
  --fade-in: linear-gradient(to bottom, #fff 0, rgba(255,255,255,0.74) calc(var(--fade) * 0.3), rgba(255,255,255,0.34) calc(var(--fade) * 0.6), rgba(255,255,255,0) var(--fade));
  --fade-out: linear-gradient(to top, #fff 0, rgba(255,255,255,0.74) calc(var(--fade) * 0.3), rgba(255,255,255,0.34) calc(var(--fade) * 0.6), rgba(255,255,255,0) var(--fade));
}
.hero__media::after,
.segment__media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.hero__media::after { background: var(--fade-out); }
.segment__media::after { background: var(--fade-in), var(--fade-out); }

.segment__copy {
  position: relative;
  height: 100%;
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.segment--public .segment__copy {
  justify-content: flex-start;
  padding-top: clamp(72px, 10.4vw, 150px);
}
/* All four section headlines share one size and width, identical in EN and DE (client decision 8 Nov 2026).
   A longer German headline may wrap to a third line rather than shrink. */
.segment__title {
  margin-top: 16px;
  font-size: clamp(32px, 3.8vw, 52px);
  line-height: 1.1;
  max-width: 760px;
}
.segment__sub {
  margin-top: 22px;
  font-size: clamp(18px, 1.6vw, 21px);
  line-height: 1.45;
  color: var(--text-sub);
  max-width: 520px;
}
.segment--investors .segment__sub,
.segment--public .segment__sub { max-width: 560px; }

.segment__body {
  max-width: var(--content);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.intro {
  margin: 120px auto 0;
  max-width: 820px;
  text-align: center;
  font-size: clamp(18px, 1.6vw, 21px);
  line-height: 1.6;
  color: var(--ink);
}
.intro__title { font-size: clamp(28px, 2.6vw, 36px); line-height: 1.15; }
.intro__title + p { margin-top: 20px; }

/* ---------- Focus areas / How we work (hairline rows) ---------- */

.focus { margin-top: 96px; }
.focus .overline { margin-bottom: 8px; }
.focus__row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 64px;
  padding: 32px 0;
  border-top: 1px solid var(--line);
}
.focus__row:last-child { border-bottom: 1px solid var(--line); }
.focus__title {
  flex: 1 1 300px;
  min-width: 0;
  font-size: clamp(22px, 2.2vw, 28px);
  line-height: 1.15;
}
.focus__text {
  flex: 2 1 480px;
  min-width: 0;
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-desc);
}

/* ---------- Proof number ---------- */

.proof {
  margin-top: 110px;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 24px 72px;
}
.proof__number {
  flex: 1 1 300px;
  min-width: 0;
  font-size: clamp(64px, 7vw, 96px);
  line-height: 1;
}
.proof__copy { flex: 2 1 480px; min-width: 0; }
.proof__lead { font-size: clamp(22px, 2.2vw, 28px); line-height: 1.2; }
.proof__text {
  margin-top: 14px;
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-desc);
}
.proof__note {
  margin-top: 18px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-caption);
}

/* ---------- Closing line ---------- */

.closing {
  margin-top: 110px;
  padding-bottom: 40px;
  text-align: center;
}
.closing__line { font-size: clamp(28px, 3vw, 40px); line-height: 1.15; }
.closing__link {
  display: inline-block;
  margin-top: 22px;
  font-size: 18px;
  font-weight: 500;
}

/* ---------- About us ---------- */

.about {
  background: var(--white);
  padding: 160px var(--gutter) 150px;
}
.about__inner { max-width: var(--content); margin: 0 auto; }
.about__intro {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 56px 88px;
}
.about__portrait {
  flex: 1 1 440px;
  min-width: 0;
  display: flex;
  justify-content: center;
}
.about__portrait img {
  display: block;
  width: 100%;
  max-width: 440px;
  height: auto;
}
.about__copy { flex: 1 1 460px; min-width: 0; }
.about__years {
  margin-top: 16px;
  font-size: clamp(80px, 10vw, 140px);
  line-height: 1;
  letter-spacing: -0.02em;
}
.about__tagline {
  margin-top: 24px;
  font-size: clamp(28px, 2.6vw, 36px);
  line-height: 1.2;
}
.about__text {
  margin-top: 28px;
  font-size: 19px;
  line-height: 1.6;
  color: var(--ink);
}
.about__text + .about__text { margin-top: 20px; }
.about__byline {
  margin-top: 28px;
  font-size: 15px;
  color: var(--text-caption);
}
.about__byline a { white-space: nowrap; }

.stats {
  margin-top: 120px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 48px 32px;
  text-align: center;
}
.stats__item { flex: 1 1 200px; }
.stats__number { font-size: clamp(52px, 5.4vw, 72px); line-height: 1; }
.stats__label { margin-top: 12px; font-size: 17px; color: var(--text-desc); }
.stats__note {
  margin-top: 40px;
  text-align: center;
  font-size: 15px;
  color: var(--text-caption);
}
.about .focus { margin-top: 120px; }
.about__closing {
  margin-top: 120px;
  text-align: center;
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.2;
}

/* ---------- Contact ---------- */

.contact {
  position: relative;
  overflow: hidden;
  /* white page eases into the grey contact band instead of a hard edge */
  background: linear-gradient(var(--white), var(--bg-grey) 180px);
  padding: 150px var(--gutter) 120px;
}
.contact__img {
  display: none;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 68%;
}
.contact__inner {
  position: relative;
  max-width: var(--content);
  margin: 0 auto;
  text-align: center;
}
.contact__title { font-size: clamp(44px, 5vw, 66px); line-height: 1.05; }
.contact__sub {
  margin: 20px auto 0;
  max-width: 620px;
  font-size: 19px;
  line-height: 1.6;
  color: var(--text-desc);
}
.btn-primary {
  display: inline-block;
  margin-top: 36px;
  padding: 15px 30px;
  border-radius: 999px;
  background: var(--navy);
  color: var(--white);
  font-size: 16px;
  font-weight: 500;
  transition: background-color .2s ease;
}
.btn-primary:hover { background: var(--blue); color: var(--white); }
.contact__details {
  margin-top: 40px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px 40px;
  font-size: 16px;
  color: var(--text-desc);
}

/* Optional image variant (Watzmann), see AGENTS.md §6: add class "contact--image"
   to the section and "site-footer--plain" to the footer. */
.contact--image { min-height: 1100px; }
.contact--image .contact__img { display: block; }
.contact--image .contact__title,
.contact--image .contact__sub,
.contact--image .contact__details,
.contact--image .contact__details a { color: var(--white); }
.contact--image .btn-primary { background: var(--white); color: var(--navy); }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--bg-grey);
  padding: 0 var(--gutter) 40px;
  font-size: 13px;
  color: var(--text-footer);
}
.site-footer--plain { background: var(--white); }
.site-footer__inner {
  max-width: var(--content);
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 32px;
}
.site-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
}
.site-footer a { color: var(--text-footer); }
.site-footer a:hover { color: var(--navy); }

/* ---------- Legal pages ---------- */

.legal {
  max-width: 760px;
  margin: 0 auto;
  padding: calc(var(--header-h) + 72px) var(--gutter) 120px;
}
.legal h1 { font-family: var(--font-head); font-weight: 600; font-size: clamp(36px, 5vw, 48px); line-height: 1.1; margin-bottom: 32px; }
.legal h2 { font-family: var(--font-head); font-weight: 600; font-size: 26px; margin: 40px 0 12px; }
.legal p,
.legal li { font-size: 17px; line-height: 1.6; margin-bottom: 14px; }
.legal ul { padding-left: 22px; }
.legal li { margin-bottom: 6px; }
.todo { background: #FFF4CC; }

/* =========================================================
   Responsive
   ========================================================= */

/* Narrow desktops / landscape tablets: headline column meets the image subject,
   so soften the left part of the image behind the text. */
@media (min-width: 900px) and (max-width: 1279px) {
  .hero__copy::before,
  .segment__copy::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 calc(50% - 50vw);
    width: 70vw;
    background: linear-gradient(90deg, rgba(255,255,255,0.88) 0%, rgba(255,255,255,0.7) 55%, rgba(255,255,255,0) 100%);
    pointer-events: none;
  }
  .hero__copy > *,
  .segment__copy > * { position: relative; }
  .hero__title, .segment__title { max-width: 48vw; }
  .hero__sub, .segment__sub { max-width: 44vw; }
}

/* Navigation collapses into logo + menu button with a full-screen overlay. */
@media (max-width: 999px) {
  .js .nav { flex-wrap: nowrap; }
  .js .nav__toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-right: -10px;
    padding: 0;
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: var(--nav-ink);
    cursor: pointer;
  }
  .nav__toggle-icon,
  .nav__toggle-icon::before {
    display: block;
    width: 20px;
    height: 1.5px;
    background: currentColor;
    transition: transform .25s ease;
  }
  .nav__toggle-icon { position: relative; transform: translateY(-3.5px); }
  .nav__toggle-icon::before { content: ""; position: absolute; left: 0; top: 7px; }
  .nav-open .nav__toggle-icon { transform: translateY(0) rotate(45deg); }
  .nav-open .nav__toggle-icon::before { transform: translateY(-7px) rotate(-90deg); }

  .js .nav__links,
  .js .nav__lang { display: none; }

  .nav-open { overflow: hidden; }
  .nav-open .site-header {
    bottom: 0;
    overflow-y: auto;
    background: var(--white);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .nav-open .nav { flex-wrap: wrap; align-content: flex-start; }
  .nav-open .nav__links {
    display: flex;
    order: 3;
    flex: 1 0 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 32px 0 0;
    font-size: 30px;
    font-weight: 600;
  }
  .nav-open .nav__links .tab-light { padding: 8px 0; background: none; }
  .nav-open .nav__links .tab-light.is-active { color: var(--blue); }
  .nav-open .nav__lang {
    display: flex;
    order: 4;
    flex: 1 0 100%;
    margin-left: -9px;
    padding-top: 32px;
    font-size: 19px;
  }
}

/* Stacked layout: image first, text below on white. */
@media (max-width: 899px) {
  :root { --gutter: 20px; }

  .hero {
    height: auto;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    background: var(--white);
  }
  .hero__copy {
    height: auto;
    width: 100%;
    padding-top: calc(var(--header-h) + 48px);
    padding-bottom: 8px;
    justify-content: flex-start;
  }
  .hero__media {
    position: relative;
    flex: 1 1 auto;
    min-height: 42svh;
    order: 2;
  }
  :root { --fade: 48px; }
  .hero__media::after {
    background: linear-gradient(var(--white), rgba(255,255,255,0) 30%), var(--fade-out);
  }
  .hero__img { object-position: 72% center; }
  .hero__sub { margin-top: 18px; }
  .hero__links { margin-top: 24px; }

  .segment { padding-top: 96px; }
  .segment--first { padding-top: 64px; }
  .segment__visual { height: auto; background: none !important; }
  .segment__media {
    position: relative;
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
  }
  .segment--providers .segment__img { object-position: 78% center; }
  .segment--devices .segment__img { object-position: 74% center; }
  .segment--investors .segment__img { object-position: 72% center; }
  .segment--public .segment__img { object-position: 70% 60%; }
  .segment__copy,
  .segment--public .segment__copy {
    height: auto;
    padding-top: 36px;
    justify-content: flex-start;
  }
  .segment__sub { margin-top: 16px; }

  .intro { margin-top: 64px; text-align: left; }
  .focus { margin-top: 64px; }
  .focus__row { padding: 24px 0; }
  .focus__text, .proof__text { font-size: 17px; }
  .proof { margin-top: 72px; gap: 16px 72px; }
  .closing { margin-top: 72px; padding-bottom: 24px; }

  .about { padding: 120px var(--gutter) 96px; }
  .about__portrait img { max-width: 300px; }
  .about__text { font-size: 17px; }
  .stats { margin-top: 80px; gap: 40px 24px; }
  .stats__item { flex-basis: 140px; }
  .about .focus { margin-top: 80px; }
  .about__closing { margin-top: 80px; }

  .contact { padding: 96px var(--gutter) 80px; }
  .contact__sub { font-size: 17px; }
  .contact__details { flex-direction: column; align-items: center; gap: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
