/**
 * @file
 * Profil-Kopfbereich (Cover, Avatar-Overlap, dunkle Fläche, lokale Tabs).
 *
 * @version 2026-04-06 12:00 Europe/Berlin — Cover object-position: Theme injiziert
 *   zusätzlich eine spezifischere Regel fürs img (cns_community.theme).
 *
 * CNS-Keys (Twig cns('…'); Platzhalter .CNS-* → dist):
 * page.profile, user.profile.hero, user.profile.full.bleed, user.profile.identity.band,
 * user.profile.cover, user.profile.cover.img, user.profile.hero.inner, user.profile.identity,
 * user.profile.avatar.wrap, user.profile.avatar, user.profile.avatar.initials,
 * user.profile.identity.text, user.profile.name.row, user.profile.name,
 * user.profile.hero.tabs, user.profile.hero.tabs.primary, user.profile.hero.tabs.secondary,
 * user.profile.stats, user.profile.bio.wrap, user.profile.bio.excerpt,
 * user.profile.bio.text, user.profile.bio.more.link, user.profile.bio.modal,
 * user.profile.bio.modal.inner, user.profile.bio.modal.close, user.profile.bio.modal.heading,
 * user.profile.bio.modal.body, user.profile.meta, user.profile.meta.item,
 * user.profile.meta.icon, user.profile.meta.text, profile.nav.tab.icon.wrap,
 * profile.nav.tab.icon, profile.nav.tab.svg, profile.nav.tab.label.
 * Zustände Cover: Map-Keys user.profile.cover.* (Twig cns_data).
 */

/* Nur Cover-Streifen (Band 2); Avatar-Variablen liegen am Identity-Band. */
body.cns-4f361a5 .cns-31319ec {
  margin-bottom: 0;
  border-radius: 0;
  /* Seitliche Flächen, wenn Cover schmaler als 100vw (max. 2500px) */
  background: var(--cns-profile-hero-bg, #18191a);
  /* overflow: hidden würde Fallback-Modal (ohne dialog top-layer) abschneiden */
  overflow: visible;
}

/*
 * Cover: max. 2500px breit, Höhe aus 2500×576 (max. 576px), Zuschneiden mit object-fit.
 * Lage des Motivs: --cns-cover-object-position (wird pro Nutzer per Theme gesetzt, z. B. 50% 40%).
 */
body.cns-4f361a5 {
  --cns-cover-max-width: 2500px;
  --cns-cover-max-height: 576px;
  --cns-cover-object-position: center 40%;
}

body.cns-4f361a5 .cns-95247f4 {
  /* Eine Größe für Avatar-Kante + 50 %-Überlappung über dem Cover. */
  --cns-profile-avatar-size: 104px;
  margin-bottom: 1.25rem;
  border-radius: 0 0 12px 12px;
  background: var(--cns-profile-hero-bg, #18191a);
  color: var(--cns-profile-hero-text, #e4e6eb);
}

@media (min-width: 576px) {
  body.cns-4f361a5 .cns-95247f4 {
    --cns-profile-avatar-size: 132px;
  }
}

@media (min-width: 992px) {
  body.cns-4f361a5 .cns-95247f4 {
    --cns-profile-avatar-size: 168px;
  }
}

body.cns-4f361a5 .cns-cb81737 {
  position: relative;
  z-index: 0;
  width: 100%;
  max-width: min(100%, var(--cns-cover-max-width, 2500px));
  margin-inline: auto;
  margin-block: 0;
  padding: 0;
  background: linear-gradient(135deg, #2d3748 0%, #1a202c 50%, #2d3748 100%);
}

/*
 * Mit Bild: Breite bis 2500px, Seitenverhältnis 2500:576, aber nie höher als 576px.
 * Schmaler Viewport → proportional niedrigere Höhe (aspect-ratio).
 */
body.cns-4f361a5 .cns-cb81737:not([data-cns-2355112]) {
  aspect-ratio: 2500 / 576;
  max-height: var(--cns-cover-max-height, 576px);
  width: 100%;
  max-width: min(100%, var(--cns-cover-max-width, 2500px));
  overflow: hidden;
  line-height: 0;
}

/* Nur ohne Bild: Platzhalter, gleiche max. Breite wie mit Bild. */
body.cns-4f361a5 [data-cns-0b87fcb][data-cns-2355112] {
  max-width: min(100%, var(--cns-cover-max-width, 2500px));
  margin-inline: auto;
  min-height: 160px;
}

@media (min-width: 576px) {
  body.cns-4f361a5 [data-cns-0b87fcb][data-cns-2355112] {
    min-height: 200px;
  }
}

body.cns-4f361a5 .cns-f05149c {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: var(--cns-cover-object-position, center 40%);
  vertical-align: top;
}

body.cns-4f361a5 .cns-b95c759 {
  position: relative;
  z-index: 1;
  padding: 0 0 0.5rem;
}

/*
 * Zeile unter dem Cover: Avatar ragt zu genau 50 % in das Titelbild (nach oben).
 * Infos: 30 px unter der Cover-Kante, rechts neben dem Profilbild (Flex).
 */
body.cns-4f361a5 .cns-83a8388 {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1rem 1.25rem;
  padding-block: 0;
  padding-inline-start: 40px;
  padding-inline-end: 0.25rem;
}

body.cns-4f361a5 .cns-4bf2ca6 {
  flex: 0 0 auto;
  position: relative;
  z-index: 2;
  /* Hälfte der Avatar-Höhe über dem unteren Cover-Rand. */
  margin-top: calc(-0.5 * var(--cns-profile-avatar-size, 104px));
}

body.cns-4f361a5 .cns-9d7b314 {
  display: block;
  width: var(--cns-profile-avatar-size, 104px);
  height: var(--cns-profile-avatar-size, 104px);
  border-radius: 12px;
  border: 4px solid var(--cns-profile-hero-bg, #18191a);
  object-fit: cover;
  box-sizing: border-box;
}

body.cns-4f361a5 .cns-2a04385 {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(1.75rem, 5vw, 2.75rem);
  font-weight: 700;
  letter-spacing: 0.02em;
  background: linear-gradient(145deg, #3d4f6f 0%, #2a3447 100%);
  color: #f0f2f5;
}

body.cns-4f361a5 .cns-8ac1bb8 {
  flex: 1 1 200px;
  min-width: 0;
  /* 30 px unter dem Headerbild (untere Cover-Kante); rechts vom Avatar via Flex + gap. */
  padding-top: 30px;
  padding-bottom: 30px;
}

/* Profilname + Primär-Tabs: Flex-Zeile → cns-user-profile-identity-band.html.twig (D-10). */
body.cns-4f361a5 .cns-12195ff .cns-024dd89 {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
}

body.cns-4f361a5 .cns-024dd89 {
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 700;
  line-height: 1.2;
  color: var(--cns-profile-hero-heading, #fff);
}

body.cns-4f361a5 .cns-773a137 {
  margin: 0 0 0.35rem;
  font-size: 0.9rem;
  color: var(--cns-profile-hero-muted, #b0b3b8);
}

/* Biografie: PRIO D-10/D-11 — Layout/Typo/Spacing über Twig cns(); Rest = Semantik + Kürzung. */
body.cns-4f361a5 .cns-a884238 {
  /* Zweizeilen-Kappe: em bezieht sich auf font-size-Utility am gleichen Element (Twig). */
  max-height: calc(1.5em * 2);
}

body.cns-4f361a5 .cns-23b5d40 {
  color: var(--cns-profile-hero-text, #e4e6eb);
}

/* ProcessedText (Klartext + filter_autop): Absätze als <p>, einzelne Umbrüche als <br>. */
body.cns-4f361a5 .cns-23b5d40 p {
  margin: 0 0 0.5em;
}

body.cns-4f361a5 .cns-23b5d40 p:last-child {
  margin-bottom: 0;
}

/* Link: Kontextfarben + feine Typo ohne zentrales Utility (PRIO D-11 Rest). */
body.cns-4f361a5 .cns-eb45929 {
  background: none;
  color: var(--cns-profile-hero-muted, #b0b3b8);
  letter-spacing: 0.06em;
}

body.cns-4f361a5 .cns-eb45929:hover,
body.cns-4f361a5 .cns-eb45929:focus-visible {
  color: var(--cns-profile-hero-text, #e4e6eb);
  outline: none;
}

body.cns-4f361a5 .cns-78079d9 {
  padding: 0;
  border: none;
  max-width: none;
  max-height: none;
  background: transparent;
  width: 100%;
  height: 100%;
  max-width: 100vw;
  max-height: 100vh;
}

body.cns-4f361a5 .cns-78079d9[open] {
  display: flex;
  align-items: center;
  justify-content: center;
}

body.cns-4f361a5 .cns-78079d9::backdrop {
  background: rgba(0, 0, 0, 0.55);
}

body.cns-4f361a5 .cns-79af7c1 {
  box-sizing: border-box;
  position: relative;
  width: 50vw;
  max-width: calc(100vw - 20px);
  max-height: min(80vh, calc(100vh - 40px));
  margin: auto;
  padding: 1.25rem 1.35rem 1.35rem;
  overflow: auto;
  border-radius: 12px;
  background: var(--cns-profile-hero-bg, #18191a);
  color: var(--cns-profile-hero-text, #e4e6eb);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
}

@media (max-width: 767.98px) {
  body.cns-4f361a5 .cns-79af7c1 {
    width: calc(100vw - 20px);
    margin: 10px auto;
  }
}

body.cns-4f361a5 .cns-e369820 {
  color: var(--cns-profile-hero-heading, #fff);
}

body.cns-4f361a5 .cns-7291f81 {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  width: 2.25rem;
  height: 2.25rem;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--cns-profile-hero-text, #e4e6eb);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

body.cns-4f361a5 .cns-7291f81:hover,
body.cns-4f361a5 .cns-7291f81:focus-visible {
  background: rgba(255, 255, 255, 0.14);
  outline: none;
}

body.cns-4f361a5 .cns-c60da6f {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.875rem;
  color: var(--cns-profile-hero-muted, #b0b3b8);
}

body.cns-4f361a5 .cns-75a9915 {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

body.cns-4f361a5 .cns-489b467 {
  display: inline-flex;
  opacity: 0.9;
  color: var(--cns-profile-hero-muted, #b0b3b8);
}

/* Lokale Aufgaben: Primär neben dem Namen, Sekundär darunter mit Trennlinie. */
body.cns-4f361a5 .cns-9f0d390 {
  flex: 0 0 auto;
  margin-inline-start: auto;
  border-top: none;
  padding-top: 0;
}

body.cns-4f361a5 .cns-ece3003 {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 0.25rem;
  margin-top: 0.25rem;
}

body.cns-4f361a5 .cns-965e201 ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
  border: none;
}

body.cns-4f361a5 .cns-9f0d390 ul {
  justify-content: flex-end;
}

body.cns-4f361a5 .cns-965e201 ul li {
  margin: 0;
  padding: 0;
  list-style: none;
}

body.cns-4f361a5 .cns-965e201 ul a {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 0.85rem;
  border-radius: 8px;
  color: var(--cns-profile-hero-muted, #b0b3b8);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
}

body.cns-4f361a5 .cns-cd87c7a,
body.cns-4f361a5 .cns-3690490 {
  display: inline-flex;
  align-items: center;
  margin-inline-end: 0.4rem;
}

body.cns-4f361a5 .cns-541c84c {
  display: block;
}

body.cns-4f361a5 .cns-e0bb40f {
  line-height: 1.2;
}

body.cns-4f361a5 .cns-965e201 ul a:hover,
body.cns-4f361a5 .cns-965e201 ul a:focus {
  background: rgba(255, 255, 255, 0.06);
  color: var(--cns-profile-hero-text, #e4e6eb);
}

body.cns-4f361a5 .cns-965e201 ul a.is-active {
  color: var(--cns-profile-tab-active, #4dabf7);
  box-shadow: inset 0 -2px 0 0 var(--cns-profile-tab-active, #4dabf7);
  border-radius: 8px 8px 0 0;
  background: transparent;
}

body.cns-4f361a5 .cns-965e201 ul + h2 + ul {
  margin-top: 0.35rem;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.85rem;
}

