/* Referenzen-Seite (06.11.2026, Gespräch Fabian und Andreas): jede Referenz mit ihrem Ablauf ist eine Einheit.
   Vorher wechselten helle Kundenabschnitte und dunkle Abläufe („Was im Projekt zählt“) über die ganze Breite ab, und man sah
   nicht, welcher Ablauf zu welchem Kunden gehört. Jetzt:
   .rf-liste            heller Grund, zählt die Einheiten (01 bis 04 über jeder Karte, nur Gestaltung, kein Text im HTML)
   article.rf-fall      eine Karte je Referenz: oben der Kunde (section-light), darunter eingerückt der dunkle Ablauf
   .rf-reiter           Reiter mit dem Kundennamen, sitzt auf der Oberkante des Ablaufs wie bei einer Akte
   Texte, Bilder, Anker und die Klassen, die scripts/validate-site.mjs erwartet, bleiben unverändert.
   Die Datei wird vor marke-v2.css geladen (die muss das letzte Stylesheet sein), darum tragen einige Regeln
   „:root body“ für genug Gewicht. */

.rf-liste{
  --rf-rand:clamp(24px,5vw,64px);   /* Innenabstand der Karte, Text oben und Ablauf unten stehen auf derselben Linie */
  --rf-einzug:12px;                 /* so weit ist der Ablauf in die Karte eingerückt (32 px Kartenecke = 12 + 20) */
  counter-reset:rf;
  padding:0 0 clamp(88px,10vw,140px);
  background:var(--m-weiss);
  color:var(--m-text);
}

/* Karte */
.rf-fall{
  counter-increment:rf;
  position:relative;
  width:var(--shell);
  margin:clamp(96px,9vw,128px) auto 0;
  border:1px solid var(--m-linie);
  border-radius:var(--radius-l);
  background:var(--m-hell);
}
.rf-fall:first-child{margin-top:clamp(64px,6vw,80px)}

/* Nummer über der Karte, mit feiner Linie bis zum rechten Rand */
.rf-fall::before{
  content:counter(rf,decimal-leading-zero);
  content:counter(rf,decimal-leading-zero) / "";
  position:absolute;
  left:-1px;
  right:-1px;
  bottom:calc(100% + 16px);
  background:linear-gradient(var(--m-linie),var(--m-linie)) right center / calc(100% - 44px) 1px no-repeat;
  color:var(--m-knopf);
  font-size:15px;
  font-weight:600;
  line-height:20px;
  font-variant-numeric:tabular-nums;
  pointer-events:none;
}

/* Sprungziele (#hagebau usw.) unter dem festen Kopf mit Nummer sichtbar lassen */
.rf-fall>.section[id]{scroll-margin-top:124px}
.rf-fall .shell{width:auto;margin:0}

/* Oberer Teil: Kunde */
:root body .rf-fall>.section-light{background:transparent}
.rf-fall>.section-light{padding:var(--rf-rand) var(--rf-rand) calc(var(--rf-rand) + 22px)}
.rf-fall .v6-reference-hero{grid-template-columns:minmax(0,.95fr) minmax(0,1.05fr);gap:clamp(28px,4.4vw,64px);align-items:stretch}
.rf-fall .v6-reference-hero figure{min-height:400px;border-radius:var(--radius-m)}
.rf-fall .v6-reference-hero>div>.eyebrow{margin-bottom:16px}
.rf-fall .v6-reference-hero>div>.section-title{margin-bottom:22px}
.rf-fall .v6-reference-hero>div>.lead{margin:0}
.rf-fall .v6-reference-hero>div>.lead+.lead{margin-top:16px}

/* Unterer Teil: Ablauf, eingerückt und mit dem Reiter angedockt */
.rf-fall>.v22-reference-flow{
  position:relative;
  margin:0 var(--rf-einzug) var(--rf-einzug);
  padding:clamp(36px,4.4vw,56px) calc(var(--rf-rand) - var(--rf-einzug)) calc(var(--rf-rand) - var(--rf-einzug));
  border-radius:var(--radius-m);
  color:var(--m-auf-dunkel);
}
.rf-reiter{
  position:absolute;
  bottom:100%;
  left:calc(var(--rf-rand) - var(--rf-einzug));
  margin:0;
  padding:10px 18px 6px;
  border-radius:var(--radius-s) var(--radius-s) 0 0;
  background:var(--m-buehne);
  color:var(--m-auf-dunkel);
  font-size:15px;
  font-weight:600;
  line-height:20px;
  white-space:nowrap;
}
/* weiche Übergänge links und rechts vom Reiter in die Oberkante des Ablaufs */
.rf-reiter::before,.rf-reiter::after{content:"";position:absolute;bottom:0;width:10px;height:10px;pointer-events:none}
.rf-reiter::before{right:100%;background:radial-gradient(circle at 0 0,transparent 9.5px,var(--m-buehne) 10px)}
.rf-reiter::after{left:100%;background:radial-gradient(circle at 100% 0,transparent 9.5px,var(--m-buehne) 10px)}

.rf-fall>.v22-reference-flow .section-head{gap:clamp(20px,4vw,56px);margin-bottom:clamp(28px,3.4vw,44px)}
:root body .rf-fall>.v22-reference-flow .section-title{font-size:clamp(28px,3.1vw,42px);line-height:1.1}
.rf-fall>.v22-reference-flow .section-head .eyebrow{margin-bottom:14px}

/* Ablaufbild: ganze Breite der Karte, Bild in seinem eigenen Format (kein Rand oben und unten, nichts abgeschnitten) */
.rf-fall .v22-reference-journey{width:auto;margin:0;border-radius:var(--radius-m);box-shadow:none}
.rf-fall .v22-reference-journey>img{height:auto;aspect-ratio:16/9;object-fit:contain}
.rf-fall .v22-reference-journey>img[width="1619"]{aspect-ratio:1619/972}
.rf-fall .v22-reference-journey figcaption strong{font-size:14px}
.rf-fall .v22-reference-journey figcaption small{color:var(--m-auf-dunkel-neben);font-size:13px;line-height:1.4}

/* Abschluss: Die Frage ist seit 06.11.2026 länger („Wo kann in Ihrem Betrieb die Wertschöpfung gesteigert werden?“).
   In der Standardgröße (bis 70 px) wären es fünf Zeilen und am Handy würde „Wertschöpfung“ mitten im Wort getrennt. */
.rf-liste~.section .contact-panel h2{font-size:clamp(30px,3.4vw,48px);line-height:1.06;text-wrap:balance}

/* Tablet und Handy: Schritte unter dem Bild statt darüber, damit Bild und Text ganz lesbar bleiben */
@media (max-width:900px){
  .rf-fall .v6-reference-hero{grid-template-columns:minmax(0,1fr)}
  .rf-fall .v6-reference-hero figure{min-height:clamp(200px,40vw,340px)}
  .rf-fall .v22-reference-journey::after{display:none}
  .rf-fall .v22-reference-journey figcaption{position:relative;left:auto;right:auto;bottom:auto;border:0;border-top:1px solid rgba(183,225,246,.17);border-radius:0;background:#061523;-webkit-backdrop-filter:none;backdrop-filter:none}
  /* Reiter bündig an der linken Kante (wie bei einer Akte), sonst stößt die weiche Ecke an die Rundung des Ablaufs */
  .rf-fall>.v22-reference-flow{border-top-left-radius:0}
  .rf-reiter{left:0;padding-left:calc(var(--rf-rand) - var(--rf-einzug));border-radius:var(--radius-m) var(--radius-s) 0 0}
  .rf-reiter::before{display:none}
}
@media (max-width:700px){
  .rf-liste{--rf-einzug:10px}
  .rf-fall{border-radius:var(--radius-m)}
  .rf-fall>.v22-reference-flow{border-radius:0 var(--radius-s) var(--radius-s)}
  .rf-fall .v22-reference-journey{border-radius:var(--radius-s)}
  .rf-fall .v22-reference-journey figcaption{grid-template-columns:minmax(0,1fr)}
  .rf-fall .v22-reference-journey figcaption>span{grid-template-columns:24px minmax(0,1fr);gap:2px 12px;min-height:0;padding:12px 14px}
  .rf-fall .v22-reference-journey figcaption>span+span{border-left:0;border-top:1px solid rgba(255,255,255,.1)}
  .rf-fall .v22-reference-journey figcaption b{width:24px;height:24px}
  .rf-fall .v22-reference-journey figcaption strong{font-size:15px}
  .rf-fall .v22-reference-journey figcaption small{font-size:14px}
  .rf-reiter{padding-top:9px;padding-right:14px;padding-bottom:5px;border-radius:var(--radius-s) var(--radius-s) 0 0;font-size:14px}
}
/* Runde 4 (08.11.2026): Ablaufbilder auf Referenzen nie unsichtbar. Das Einblenden (Schwelle 12 %) ließ unter dem Text einen leeren
   dunklen Streifen stehen, bis 71 px des 592 px hohen Bildes über der Bildschirmkante lagen */
:root body .rf-fall .v22-reference-journey[data-reveal]{opacity:1;transform:none}
/* Runde 5 (09.11.2026): Sales-X-Ray-Logo sitzt im Lichtpunkt des Verlaufs (30 % der Höhe) statt in der Mitte der hohen dunklen
   Bühne; beim Scrollen erscheint es so früher, statt dass oben nur der leere Verlauf steht */
@media (min-width:901px){:root body .v6-reference-hero .v20-hagebau-stage--sales-x-ray img{position:relative;top:-20%}}

/* Ablaufgrafik act legal (Fabian 10.11.2026: Aufbau wie seine Bildvorlage, aber gezeichnet statt Bild; scripts/ablauf-szene.py).
   Oben der Weg: WebERV, Sprachmodell in der geschlossenen Umgebung, Freigabe, Outlook. Darunter die Schritte und die Zusagen.
   Ruhe = fertig. Bei Maus darüber läuft ein Licht den Weg entlang und die Schritte leuchten der Reihe nach. */
.ab{margin:0;padding:clamp(20px,3vw,40px);border:1px solid rgba(149,211,242,.17);border-radius:var(--radius-m);background:linear-gradient(180deg,#0a2036,#061523 62%);color:var(--m-auf-dunkel)}
.ab small{display:block;color:var(--m-auf-dunkel-neben);font-size:14px;line-height:1.4}
.ab svg{flex:none;width:16px;height:16px}
.ab-weg{display:grid;grid-template-columns:minmax(0,1fr) clamp(36px,5vw,72px) minmax(0,1.45fr) clamp(118px,11vw,150px) minmax(0,1fr);align-items:stretch;padding-top:16px}
.ab-ort,.ab-kern{display:grid;justify-items:center;align-content:center;gap:6px;min-height:176px;padding:22px 16px;border:1px solid rgba(183,225,246,.17);border-radius:var(--radius-m);background:rgba(255,255,255,.035);text-align:center}
.ab-ort b,.ab-kern b{font-size:20px;font-weight:600;line-height:1.2;letter-spacing:-.01em}
.ab-kern{position:relative;padding:34px 20px 24px;border-color:rgba(41,151,255,.6);background:rgba(41,151,255,.08)}
.ab-schloss{position:absolute;top:0;left:50%;transform:translate(-50%,-50%);display:inline-flex;align-items:center;gap:7px;margin:0;padding:5px 13px;border:1px solid rgba(41,151,255,.6);border-radius:var(--radius-pill);background:#0a2036;color:#a9d5ff;font-size:13px;font-weight:600;line-height:18px;white-space:nowrap}
.ab-chips{display:flex;flex-wrap:wrap;justify-content:center;gap:6px;margin:10px 0 0}
.ab-chips span{padding:4px 10px;border:1px solid rgba(183,225,246,.22);border-radius:var(--radius-pill);color:var(--m-auf-dunkel);font-size:13px;line-height:18px}
/* Blätter und Kalender: einfache Formen, keine Logos */
.ab-blatt{position:relative;width:44px;height:54px;margin:4px 0 8px}
.ab-blatt i{position:absolute;inset:0;border:1px solid rgba(183,225,246,.42);border-radius:var(--radius-xs);background:#0d2a45}
.ab-blatt i:nth-child(1){transform:translate(-10px,-5px) rotate(-7deg);opacity:.5}
.ab-blatt i:nth-child(2){transform:translate(-5px,-2px) rotate(-3.5deg);opacity:.78}
.ab-blatt i:nth-child(3)::before{content:"";position:absolute;left:8px;right:8px;top:11px;height:2px;background:rgba(183,225,246,.62);box-shadow:0 8px 0 rgba(183,225,246,.36),0 16px 0 rgba(183,225,246,.36),0 24px 0 rgba(183,225,246,.2)}
.ab-kal{position:relative;width:58px;height:50px;margin:4px 0 8px;border:1px solid rgba(183,225,246,.42);border-radius:var(--radius-xs);background:#0d2a45;overflow:hidden}
.ab-kal::before{content:"";position:absolute;left:0;right:0;top:0;height:11px;background:rgba(183,225,246,.24)}
.ab-kal::after{content:"";position:absolute;left:7px;top:18px;width:8px;height:6px;border-radius:var(--radius-xs);background:rgba(183,225,246,.3);box-shadow:12px 0 0 rgba(183,225,246,.3),24px 0 0 rgba(183,225,246,.3),36px 0 0 rgba(183,225,246,.3),0 10px 0 rgba(183,225,246,.3),12px 10px 0 var(--m-blau),24px 10px 0 var(--m-blau),36px 10px 0 rgba(183,225,246,.3),0 20px 0 rgba(183,225,246,.3),12px 20px 0 rgba(183,225,246,.3),24px 20px 0 rgba(183,225,246,.3),36px 20px 0 rgba(183,225,246,.3)}
/* Verbindungen */
.ab-pfeil{position:relative;align-self:center;height:2px;background:linear-gradient(90deg,rgba(41,151,255,.3),rgba(41,151,255,.95))}
.ab-pfeil::after{content:"";position:absolute;right:1px;top:50%;width:8px;height:8px;border-top:2px solid var(--m-blau);border-right:2px solid var(--m-blau);transform:translateY(-50%) rotate(45deg)}
.ab-pfeil::before{content:"";position:absolute;left:0;top:50%;width:26px;height:4px;border-radius:var(--radius-pill);background:#d6ecff;opacity:0;transform:translateY(-50%)}
.ab-frei{position:absolute;z-index:1;left:50%;top:50%;transform:translate(-50%,-50%);display:inline-flex;align-items:center;gap:6px;padding:6px 12px;border:1px solid rgba(94,207,143,.5);border-radius:var(--radius-pill);background:#0b2a2a;color:#8ee3b2;font-size:13px;font-weight:600;line-height:18px;white-space:nowrap}
/* Schritte */
.ab-mensch{display:grid;place-items:center;width:54px;height:54px;margin:4px 0 8px;border:1px solid rgba(183,225,246,.42);border-radius:50%;background:#0d2a45;color:#cfe8fb}
.ab .ab-mensch svg{width:28px;height:28px}
.ab-kern--offen{padding-top:24px}
.ab-schritte--4{grid-template-columns:repeat(4,minmax(0,1fr))!important}
.ab-schritte{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:10px;margin:clamp(22px,2.6vw,34px) 0 0;padding:0;list-style:none}
.ab-schritte li{display:grid;align-content:start;gap:4px;padding:14px 14px 16px;border:1px solid rgba(183,225,246,.14);border-radius:var(--radius-s);background:rgba(3,17,29,.55)}
.ab-schritte b{display:grid;place-items:center;width:28px;height:28px;margin-bottom:6px;border:1px solid rgba(122,208,249,.3);border-radius:50%;color:#8fd4f7;font-size:12px;font-weight:600}
.ab-schritte strong{font-size:14px;font-weight:600;line-height:1.3}
/* Lange Wörter wie „Prozessmanagement“ passen am Handy nicht in eine halbe Zeile: Trennstelle steht im Text (weiches Trennzeichen) */
.ab-schritte li{min-width:0}
.ab-schritte :is(strong,small){-webkit-hyphens:manual;hyphens:manual;overflow-wrap:anywhere}
.ab-schritte small{font-size:13px}
.ab-schritte .ab-ja{border-color:rgba(94,207,143,.4);background:rgba(74,183,120,.09)}
.ab-schritte .ab-ja b{border-color:rgba(94,207,143,.45);background:rgba(74,183,120,.14);color:#8ee3b2}
/* Zusagen */
.ab-zusagen{display:flex;flex-wrap:wrap;align-items:center;gap:8px 22px;margin-top:clamp(18px,2.2vw,26px);padding-top:clamp(16px,2vw,22px);border-top:1px solid rgba(183,225,246,.14)}
.ab-zusagen p{margin:0;color:var(--m-auf-dunkel-neben);font-size:14px;line-height:20px}
.ab-zusagen ul{display:flex;flex-wrap:wrap;gap:8px 22px;margin:0;padding:0;list-style:none}
.ab-zusagen li{display:inline-flex;align-items:center;gap:7px;font-size:14px;font-weight:600;line-height:20px}
.ab-zusagen svg{color:#8fd4f7}
@media (hover:hover) and (pointer:fine) and (prefers-reduced-motion:no-preference){
  .ab:hover .ab-pfeil::before{animation:ab-licht 2.6s ease-in-out infinite}
  .ab:hover .ab-tor::before{animation-delay:.9s}
  .ab:hover .ab-schritte li{animation:ab-schritt 4.2s ease-in-out infinite}
  .ab:hover .ab-schritte li:nth-child(2){animation-delay:.45s}
  .ab:hover .ab-schritte li:nth-child(3){animation-delay:.9s}
  .ab:hover .ab-schritte li:nth-child(4){animation-delay:1.35s}
  .ab:hover .ab-schritte li:nth-child(5){animation-delay:1.8s}
  .ab:hover .ab-schritte li:nth-child(6){animation-delay:2.25s}
  .ab:hover .ab-schritte li:nth-child(7){animation-delay:2.7s}
}
@keyframes ab-licht{0%{left:0;opacity:0}15%{opacity:.95}85%{opacity:.95}100%{left:calc(100% - 26px);opacity:0}}
@keyframes ab-schritt{0%,22%,100%{border-color:rgba(183,225,246,.14)}8%{border-color:rgba(143,212,247,.85)}}
@media (max-width:1100px){
  .ab-schritte{grid-template-columns:repeat(4,minmax(0,1fr))}
}
@media (max-width:900px){
  .ab-weg{grid-template-columns:minmax(0,1fr);justify-items:stretch}
  .ab-ort,.ab-kern{min-height:0}
  .ab-kern{margin-top:10px}
  .ab-kern:not(.ab-kern--offen){margin-top:20px}
  .ab-pfeil{justify-self:center;width:2px;height:34px;background:linear-gradient(180deg,rgba(41,151,255,.3),rgba(41,151,255,.95))}
  .ab-pfeil::after{right:auto;left:50%;top:auto;bottom:1px;transform:translateX(-50%) rotate(135deg)}
  .ab-pfeil::before{display:none}
  .ab-tor{height:64px}
}
@media (max-width:700px){
  .ab{padding:18px 14px;border-radius:var(--radius-s)}
  .ab-schritte,.ab-schritte--4{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px}
  .ab-schritte li{padding:12px 12px 14px}
  .ab-zusagen ul{display:grid;grid-template-columns:minmax(0,1fr);gap:8px}
}


/* Referenz CONFIDA Villach (seit 11.11.2026): helles Logo-Feld wie bei act legal und Kärnten Werbung, das Logo ist breit und flach */
.v20-hagebau-stage--confida{background:radial-gradient(circle at 50% 40%,rgba(255,255,255,.98) 0,rgba(247,250,253,.96) 38%,rgba(224,233,242,.98) 100%);border-color:rgba(30,66,104,.1)}
:root body .v6-reference-hero .v20-hagebau-stage--confida>img{width:min(62%,380px);height:auto;filter:drop-shadow(0 22px 34px rgba(20,52,88,.12))}
