/* Funfacts-Rubrik (public/facts.js): Karten im Quantum-Neon-Stil, je Kategorie eine Akzentfarbe. Setzt app.css voraus (.panel, .ph, .chips, .chip, Variablen). */
.facts { --fx-pad: 20px; }
.facts .ph { padding-bottom: 14px; }
.facts .ph h2 { white-space: nowrap; }

/* Akzentfarben je Kategorie (als RGB-Tripel, damit sich Glühen und Rahmen davon ableiten) */
.fx-rekord { --ac: var(--amber-hi); --ac-rgb: 255, 176, 0; }
.fx-meilenstein { --ac: var(--cyan); --ac-rgb: 53, 240, 255; }
.fx-serie { --ac: var(--pink); --ac-rgb: 255, 46, 136; }
.fx-kurios { --ac: var(--pos); --ac-rgb: 99, 242, 160; }

.fx-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); gap: 14px; padding: 2px var(--fx-pad) var(--fx-pad); }

.ffact { position: relative; display: grid; grid-template-columns: 46px minmax(0, 1fr); gap: 14px; align-items: start; padding: 16px 16px 16px 18px; min-width: 0; overflow: hidden;
  border-radius: 14px; border: 1px solid rgba(var(--ac-rgb), .3);
  background: linear-gradient(160deg, rgba(var(--ac-rgb), .09), rgba(8, 6, 38, .55) 46%), rgba(10, 7, 44, .7);
  box-shadow: inset 3px 0 0 var(--ac), 0 0 0 rgba(var(--ac-rgb), 0); transition: transform .2s, box-shadow .2s, border-color .2s; }
.ffact:hover { transform: translateY(-2px); border-color: rgba(var(--ac-rgb), .6); box-shadow: inset 3px 0 0 var(--ac), 0 8px 26px rgba(var(--ac-rgb), .18); }
.ffact[hidden] { display: none; }

/* Wasserzeichen-Symbol unten rechts */
.fx-wm { position: absolute; right: -14px; bottom: -18px; width: 108px; height: 108px; color: var(--ac); opacity: .07; stroke-width: 1.2; pointer-events: none; }

.fx-ic { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 12px; color: var(--ac);
  background: radial-gradient(circle at 30% 25%, rgba(var(--ac-rgb), .28), rgba(var(--ac-rgb), .06) 70%); border: 1px solid rgba(var(--ac-rgb), .45);
  box-shadow: 0 0 16px rgba(var(--ac-rgb), .25), inset 0 0 10px rgba(var(--ac-rgb), .12); }
.fx-svg { width: 25px; height: 25px; filter: drop-shadow(0 0 5px rgba(var(--ac-rgb), .7)); }

.fx-body { position: relative; min-width: 0; }
.fx-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; margin-bottom: 3px; }
.fx-meta b { font-family: var(--f-display); font-weight: 700; font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--ac); }
.fx-comp { font-family: var(--f-display); font-weight: 700; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--label);
  padding: 1px 8px; border-radius: 999px; border: 1px solid var(--line); background: rgba(14, 10, 52, .8); }
.ffact h3 { margin: 0 0 6px; font-family: var(--f-display); font-weight: 700; font-size: 20px; line-height: 1.1; letter-spacing: .06em; text-transform: uppercase; color: #fff; text-wrap: balance; overflow-wrap: anywhere; }
.ffact p { margin: 0; font-size: 15.5px; line-height: 1.42; color: var(--text); opacity: .92; overflow-wrap: anywhere; text-wrap: pretty; }

.fx-empty { margin: 0; padding: 8px var(--fx-pad) 26px; color: var(--muted); }
.fx-foot { display: flex; justify-content: flex-end; padding: 0 var(--fx-pad) 18px; }
.fx-more { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 999px; text-decoration: none; font-family: var(--f-display); font-weight: 700; font-size: 14px; letter-spacing: .12em; text-transform: uppercase;
  color: #fff; border: 1px solid var(--frame-hi); background: rgba(40, 20, 120, .5); transition: box-shadow .2s, background .2s; }
.fx-more:hover { background: linear-gradient(135deg, #8d2cff, #4d1fd6); box-shadow: 0 0 14px rgba(160, 70, 255, .55); }

/* Kurzansicht: etwas luftiger auf breiten Schirmen */
.facts-compact .fx-grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }

@media (max-width: 640px) {
  .facts { --fx-pad: 14px; }
  .facts .ph { padding: 16px 14px 12px; }
  .fx-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .ffact { grid-template-columns: 40px minmax(0, 1fr); gap: 12px; padding: 14px 14px 14px 16px; }
  .fx-ic { width: 40px; height: 40px; border-radius: 11px; }
  .fx-svg { width: 22px; height: 22px; }
  .ffact h3 { font-size: 18px; }
  .ffact p { font-size: 15px; }
  .fx-chips .chip { padding: 6px 11px; }
}
@media (prefers-reduced-motion: reduce) { .ffact { transition: none; } .ffact:hover { transform: none; } }
