/* ============================================================
   flexpep – shared site styles (subpages + Startseite v2)
   Swiss-grid system · Archivo / Archivo Expanded
   Colors: canvas #EDEDED · primary #384A80 · accent #F4BAFF · ink #1B2238
   ============================================================ */

:root {
  --canvas: #EDEDED;
  --primary: #384A80;
  --accent: #F4BAFF;
  --ink: #1B2238;
  --line: rgba(56,74,128,0.18);
  --line-strong: rgba(56,74,128,0.42);
  --flag: #FCE36A;
}

html { scroll-behavior: smooth; }
body {
  background: var(--canvas);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
::selection { background: var(--accent); color: var(--ink); }

/* German compound words: hyphenate long headings so they never overflow */
h1, h2, h3 { overflow-wrap: break-word; hyphens: auto; }
p, blockquote, li, figcaption { overflow-wrap: break-word; }

.hairline { border-color: var(--line); }
.tnum { font-variant-numeric: tabular-nums; }
.eyebrow { letter-spacing: 0.22em; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Buttons ---------- */
.btn-accent { background: var(--accent); color: var(--ink); transition: box-shadow .35s ease, transform .35s ease; }
.btn-accent:hover { box-shadow: 0 0 0 1px var(--ink), 0 10px 30px -8px rgba(244,186,255,0.9); transform: translateY(-1px); }
.btn-outline { transition: background .3s ease, color .3s ease, border-color .3s ease; border: 1px solid var(--primary); color: var(--primary); }
.btn-outline:hover { background: var(--primary); color: var(--canvas); }
.btn-ghost-light { transition: background .3s ease, color .3s ease; border: 1px solid rgba(237,237,237,0.4); color: var(--canvas); }
.btn-ghost-light:hover { background: var(--canvas); color: var(--primary); border-color: var(--canvas); }

/* ---------- Nav ---------- */
.navlink { position: relative; }
.navlink::after { content: ""; position: absolute; left: 0; bottom: -6px; height: 2px; width: 0; background: var(--primary); transition: width .3s cubic-bezier(.2,.7,.2,1); }
.navlink:hover::after, .navlink.active::after { width: 100%; }

.nav-item { position: relative; }
.nav-item::after { content: ""; position: absolute; top: 100%; left: -12px; right: -12px; height: 16px; }
.nav-dd {
  position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%) translateY(8px);
  min-width: 280px; background: #fff; border: 1px solid var(--line);
  opacity: 0; visibility: hidden; transition: opacity .25s ease, transform .25s ease;
  box-shadow: 0 24px 60px -24px rgba(27,34,56,0.30); z-index: 60;
}
.nav-item:hover .nav-dd, .nav-item:focus-within .nav-dd { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.nav-dd-right { left: auto; right: 0; transform: translateY(8px); }
.nav-item:hover .nav-dd-right, .nav-item:focus-within .nav-dd-right { transform: translateY(0); }
.nav-dd a { display: block; padding: 14px 18px; border-bottom: 1px solid var(--line); transition: background .2s ease; }
.nav-dd a:last-child { border-bottom: 0; }
.nav-dd a:hover { background: var(--canvas); }
.nav-caret { transition: transform .25s ease; }
.nav-item:hover .nav-caret, .nav-item:focus-within .nav-caret { transform: rotate(180deg); }

/* ---------- Mini creature (placeholder until Uhu/Gepard/Fuchs delivered) ---------- */
.mini-creature { filter: drop-shadow(0 16px 34px rgba(27,34,56,0.18)); }
.creature-badge {
  position: absolute; bottom: 6px; right: 6px;
  font-size: 10px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  background: var(--flag); color: var(--ink); padding: 3px 8px; border: 1px solid var(--ink);
}

/* ---------- Yellow clarification flag ---------- */
.flag { background: var(--flag); box-shadow: 0 0 0 1px rgba(27,34,56,0.25); padding: 0 .18em; border-radius: 1px; }
.flag-box { background: var(--flag); border: 1px solid var(--ink); }
.flag-note { display: inline-flex; align-items: center; gap: .4em; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; background: var(--flag); color: var(--ink); padding: 3px 8px; border: 1px solid var(--ink); }

/* ---------- FAQ accordion ---------- */
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q { width: 100%; text-align: left; display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; cursor: pointer; }
.faq-ic { transition: transform .35s cubic-bezier(.2,.7,.2,1); }
.faq-item.open .faq-ic { transform: rotate(45deg); }
.faq-a { overflow: hidden; max-height: 0; transition: max-height .4s cubic-bezier(.2,.7,.2,1); }

/* ---------- Step connector (Vorgehen) ---------- */
.step-num { font-variant-numeric: tabular-nums; }

/* ---------- Count-up stat helper ---------- */
.stat { font-variant-numeric: tabular-nums; }

/* ---------- Sector / card hover ---------- */
.lift { transition: background .3s ease, transform .3s ease; }
.lift:hover { background: #fff; }

/* ---------- CTA spotlight (all final CTAs, site-wide) ---------- */
.cta-spotlight { position: relative; overflow: hidden; }
.cta-spotlight::before {
  content: ""; position: absolute; inset: 0; opacity: 0; pointer-events: none;
  transition: opacity .45s ease;
  background: radial-gradient(480px circle at var(--mx,50%) var(--my,50%),
    color-mix(in srgb, var(--accent) 85%, transparent),
    color-mix(in srgb, var(--accent) 34%, transparent) 40%,
    transparent 70%);
}
.cta-spotlight:hover::before { opacity: 1; }
.cta-spotlight .cta-layer { position: relative; z-index: 1; }
.cta-spotlight .cta-text { text-shadow: 0 2px 18px rgba(27,34,56,.55), 0 1px 3px rgba(27,34,56,.45); }
.cta-spotlight .cta-btn { box-shadow: 0 0 0 1px var(--ink), 0 12px 34px -10px rgba(27,34,56,.6); }
body[data-motion="still"] .cta-spotlight::before { display: none; }

/* ---------- On-page editor (titles, line breaks, width) ---------- */
.ed-bar { position: fixed; top: 88px; right: 16px; z-index: 95; display: flex; gap: 8px; }
.ed-toggle, .ed-reset { font: 700 13px/1 'Archivo', system-ui, sans-serif; letter-spacing: .01em; padding: .7rem 1.05rem; border: none; cursor: pointer; display: inline-flex; align-items: center; gap: .5rem; }
.ed-toggle { color: #fff; background: var(--primary); box-shadow: 0 6px 24px rgba(56,74,128,.32); transition: background .2s ease, transform .15s ease; }
.ed-toggle:hover { transform: translateY(-1px); }
.ed-dot { width: 8px; height: 8px; border-radius: 999px; background: var(--accent); }
.ed-reset { display: none; color: var(--primary); background: #fff; border: 1px solid var(--line); box-shadow: 0 4px 16px rgba(56,74,128,.16); }
body.ed-on .ed-reset { display: inline-flex; }
.ed-color { display: none; width: 34px; padding: 0; border: 1px solid var(--line); cursor: pointer; box-shadow: 0 4px 16px rgba(56,74,128,.16); }
body.ed-on .ed-color { display: inline-flex; }
.ed-color.ed-blau { background: var(--primary); }
.ed-color.ed-rosa { background: var(--accent); }
.ed-color:hover { outline: 2px solid var(--ink); outline-offset: 1px; }
body.ed-on .ed-toggle { background: var(--ink); }
body.ed-on .ed-toggle .ed-dot { background: #6EE7A8; }
body.ed-on [data-ed] { outline: 1px dashed rgba(56,74,128,.4); outline-offset: 3px; cursor: text; border-radius: 2px; transition: outline-color .2s ease, background .2s ease; }
body.ed-on [data-ed]:hover { outline-color: var(--primary); background: rgba(244,186,255,.14); }
body.ed-on [data-ed]:focus { outline: 2px solid var(--primary); background: rgba(244,186,255,.24); }
body.ed-on a[data-ed], body.ed-on [data-ed] a { pointer-events: auto; }
.ed-handle { position: absolute; top: 0; right: -7px; width: 12px; height: 100%; cursor: ew-resize; background: var(--accent); opacity: 0; border-radius: 2px; }
body.ed-on .ed-handle { opacity: .45; }
body.ed-on .ed-handle:hover { opacity: 1; }
@media print { .ed-bar, .ed-handle { display: none !important; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .cta-spotlight::before { display: none; }
}
@media print {
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .no-print { display: none !important; }
}

.hero-brk{display:none}@media (max-width:639px){.hero-brk{display:inline}}

.brk-dsk{display:inline}@media (max-width:639px){.brk-dsk{display:none}}

/* --- Accessibility: gedaempfte Text-Utilities + Custom-Labels auf WCAG-AA-Kontrast (>=4.5:1) heben --- */
html [class*="text-primary/"] { color: rgb(78, 94, 138) !important; }
html [class*="text-ink/"]     { color: rgb(84, 92, 116) !important; }
html [class*="text-canvas/"]  { color: rgb(224, 226, 233) !important; }
html .bk-label, html .kv .k, html .mq-chip .mq-arrow { color: rgb(78, 94, 138) !important; }
html .mq-chip .mq-sub, html .nf-search .q { color: rgb(84, 92, 116) !important; }
