/* Seitentitel in der Kopfzeile: siehe cockpit-kopf.js. */
.ck-navtitle { display: inline-flex; align-items: center; gap: .55rem; min-width: 0; margin-left: .75rem; color: var(--bs-body-color, inherit); }
.ck-navicon { flex: none; width: 20px; height: 20px; }
.ck-navname { font-size: 1.125rem; font-weight: 650; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hk-navbar .nav-start-wrap { min-width: 0; }
main h1.crm-page-title.ck-h1-weg { display: none !important; }
/* Untertitel einheitlich (Abnahme 30.10.2026, F5-17): Steht der Seitentitel in der Kopfzeile, entfällt auch die Zeile darunter –
   wie schon bei Cockpit, Wiedervorlagen, Pepsi, Produktwissen, Leads und Kunden. Unterseiten mit eigener Überschrift behalten sie. */
main .hk-pg-header h1.ck-h1-weg + p { display: none; }
/* Überschrift nur für Screenreader (cockpit-kopf.js setzt sie, wenn der Inhalt keine sichtbare h1 hat). */
.ck-sr-h1 { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.ck-navclock { font-size: .8125rem; font-variant-numeric: tabular-nums; color: var(--bs-secondary-color, #6b7280); margin-right: .75rem; white-space: nowrap; }
.ck-navclock[hidden] { display: none; }
/* Nur Cockpit: Kopfblock (Titel, Untertitel, Aktualisieren, Alle Leads öffnen) entfällt, Dashboard rückt nach oben. */
html[data-ck-kopf] main > div.twenty-cockpit > .hk-pg-header { display: none !important; }
/* Derselbe Kopf schon ab dem ersten Bild – beim Laden („Arbeitslage wird geladen …“), bei Rückkehr per Seitenleiste und bei
   Ladefehlern: erkennbar am Link „Alle Leads öffnen“, den nur der Cockpit-Kopf des Bündels hat. Hängt weder an data-ck-kopf
   noch an .twenty-cockpit, die beide erst später gesetzt werden (Abnahme 30.10.2026, X5-1/F4-08). */
main header.hk-pg-header:has(.pg-header-action-wrap > a.btn-secondary[href="/leads"]) { display: none !important; }
html[data-ck-kopf] main > div.twenty-cockpit { padding-top: 0; }
html[data-ck-kopf] main > div.twenty-cockpit > .ck-dash { margin-top: 0; }
@media (max-width: 600px) {
  /* Uhr am Handy nur, wenn Platz ist (cockpit-kopf.js blendet sie sonst per hidden aus). */
  .ck-navclock { margin-right: .25rem; }
  /* Handy: rechte Gruppe behält ihre Größe, der Titel nimmt den Rest und kürzt mit „…“ statt die Leiste zu sprengen. */
  .hk-navbar .nav-start-wrap { flex: 1 1 0; min-width: 0; }
  .hk-navbar .nav-end-wrap { flex: none; }
  .ck-navtitle { margin-left: .25rem; gap: .35rem; flex: 1 1 0; }
  .ck-navname { font-size: .9375rem; min-width: 0; }
  .ck-navicon { width: 18px; height: 18px; }
  /* Lange Titel (Wiedervorlagen, Produktwissen, Lead-Steuerung): kleiner und zweizeilig neben dem Icon statt nur Icon. */
  .ck-navtitle.ck-kompakt .ck-navname { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; white-space: normal; font-size: .8125rem; line-height: 1.15; -webkit-hyphens: auto; hyphens: auto; overflow-wrap: anywhere; }
  /* Pepsi (F4-04/X5-4, Anfrage Gruppe D): neben dem zusätzlichen Aktualisieren-Knopf fehlt Platz für Icon + Titel.
     „+ Lead“ dort nur als Symbol (40 × 40 px); die Beschriftung „Lead“ bleibt für Screenreader. pepsi.js blendet das Icon ein, sobald es passt. */
  html.twenty-ui[data-pepsi-nav-actions] .hk-navbar a.btn-primary[href="/leads/neu"] { width: 40px; min-width: 40px; padding: 0 !important; gap: 0 !important; }
  html.twenty-ui[data-pepsi-nav-actions] .hk-navbar a.btn-primary[href="/leads/neu"] > span { position: absolute !important; width: 1px !important; height: 1px !important; margin: -1px !important; padding: 0 !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
  /* „Suche“ als Lupe (Beschriftung bleibt per aria-label), spart Platz für den Titel. */
  .mail-preview-tools [data-search] { font-size: 0 !important; width: 40px; padding: 0 !important; display: inline-flex; align-items: center; justify-content: center; }
  .mail-preview-tools [data-search] kbd { display: none; }
  .mail-preview-tools [data-search]::before { content: ''; width: 18px; height: 18px; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") center / contain no-repeat; }
}
