/* app/shared/faehigkeitsansicht.css
   Gemeinsamer Stilblock zur Faehigkeitsansicht in Clubs, Leagues und Events.

   Loest zwei Kopien ab: den capview-/cvd-Block in clubs-06-landing-und-spaet.css
   und den rrcv-Block in roadmap_renderer.css. Es bleibt ein Praefix: cvd-.
   Jede Farbmarke traegt einen Rueckfall, damit die Regeln auch dort greifen,
   wo eine Edition die Marke nicht setzt.
*/

/* ── Kopfkacheln ─────────────────────────────────────────────────────
   2026-08-04 · Gitter statt flex, damit die zwei Zahlkacheln nicht halb
   leer bleiben, waehrend die Namenskacheln umbrechen. */
.cvd-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
  margin: 6px 0 16px;
}
.cvd-stat {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--paper, #F7F5F0);
  border: 1px solid var(--line-soft, #E1DFDB);
  border-radius: var(--r-lg, 3px);
  padding: 14px 16px;
}
.cvd-stat-v {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: 26px;
  color: var(--ink, #0D3D2D);
  line-height: 1.1;
}
/* Domaenennamen laufen lang — eine Stufe kleiner, damit alle Kacheln
   vergleichbar hoch bleiben statt einer ueber drei Zeilen. */
.cvd-stat-v.is-name {
  font-size: 16px;
  line-height: 1.32;
  overflow-wrap: break-word;
  hyphens: none;
}
.cvd-stat-k {
  font-size: 11.5px;
  color: var(--muted, #4A4A48);
  letter-spacing: 0.04em;
  margin-top: 8px;
  line-height: 1.45;
}

/* ── Liste der Domaenen ──────────────────────────────────────────── */
.cvd-list { margin-bottom: 8px; }
.cvd-sublabel {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted, #4A4A48);
  margin: 20px 0 8px;
}
details.cvd-dom {
  border: 1px solid var(--line-soft, #E1DFDB);
  border-radius: var(--r-lg, 3px);
  background: var(--white, #FFFDF9);
  margin-bottom: 8px;
  /* 2026-08-02 (p50): overflow hidden schnitt jede Sprechblase im Aufklapper
     ab. Bei drei Pixel Eckenradius braucht es das Beschneiden nicht. */
}
details.cvd-dom[open] { border-color: var(--line, #E1DFDB); }
.cvd-dom-sum {
  list-style: none;
  cursor: pointer;
  padding: 14px 18px;
  display: grid;
  /* 2026-08-04 · 214px liessen die Messzeile zweizeilig brechen und darunter
     eine Luecke bis zum Zaehlchip. 296px halten sie einzeilig. */
  grid-template-columns: 40px minmax(0, 1fr) 296px 128px 74px;
  align-items: center;
  gap: 14px;
}
.cvd-dom-sum::-webkit-details-marker { display: none; }
details.cvd-dom[open] .cvd-dom-sum { border-bottom: 1px solid var(--line-soft, #E1DFDB); }
.cvd-dom-sum:hover { background: var(--paper, #F7F5F0); }
.cvd-idx {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: 15px;
  color: #953B0F;
  text-align: center;
}
.cvd-name {
  font-weight: 600;
  font-size: 14.5px;
  color: var(--ink, #0D3D2D);
  line-height: 1.35;
}
/* 2026-08-05 · Inline hinter dem Namen brach die Messzeile bei langen
   Domaenennamen mitten im Text um. Als eigene Zeile sind alle Zeilen gleich
   aufgebaut und der Umbruch kann nicht mehr auftreten. */
.cvd-name-sub {
  display: block;
  margin-left: 0;
  font-size: 11.5px;
  color: var(--muted, #4A4A48);
  font-weight: 400;
  margin-top: 3px;
  line-height: 1.4;
}

/* ── Messbalken ──────────────────────────────────────────────────── */
.cvd-meter { min-width: 0; }
.cvd-track {
  height: 7px;
  border-radius: 999px;
  background: var(--sand, #EAE8E3);
  overflow: hidden;
}
.cvd-fill { height: 100%; border-radius: 999px; background: var(--kpi-attention, #006F8A); }
.cvd-fill.is-low { background: var(--coral-dark, #B4551D); }
.cvd-fill.is-mid { background: var(--gold, #EB7033); }
.cvd-meter-lbl {
  display: block;
  font-size: 11px;
  color: var(--muted, #4A4A48);
  margin-top: 5px;
  letter-spacing: 0.02em;
  line-height: 1.35;
}
.cvd-meter-none {
  font-size: 11px;
  color: var(--muted, #4A4A48);
  font-style: italic;
  line-height: 1.4;
}

/* ── Zaehlchip und Aufklapphinweis ───────────────────────────────── */
.cvd-count {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink, #0D3D2D);
  background: rgba(235, 112, 51, 0.12);
  border: 1px solid rgba(235, 112, 51, 0.28);
  border-radius: 999px;
  padding: 5px 10px;
  text-align: center;
  white-space: nowrap;
}
.cvd-count.is-zero {
  color: var(--muted, #4A4A48);
  background: transparent;
  border-color: var(--line-soft, #E1DFDB);
  font-weight: 400;
}
.cvd-toggle { font-size: 11px; color: var(--muted, #4A4A48); text-align: right; }
details.cvd-dom[open] .cvd-toggle::before { content: 'Close \2191'; }
details.cvd-dom:not([open]) .cvd-toggle::before { content: 'Open \2193'; }

/* ── Aufgeklappter Inhalt ────────────────────────────────────────── */
.cvd-body { padding: 16px 18px 18px; background: var(--paper, #F7F5F0); }
.cvd-outcome {
  font-size: 13px;
  color: var(--ink-soft, #2C4A3C);
  line-height: 1.6;
  margin-bottom: 14px;
  padding-left: 11px;
  border-left: 2px solid var(--gold-soft, #F0925E);
}
.cvd-area { margin-bottom: 14px; }
.cvd-area:last-child { margin-bottom: 0; }
.cvd-area-h {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted, #4A4A48);
  padding-bottom: 6px;
  border-bottom: 1px solid var(--line-soft, #E1DFDB);
  margin-bottom: 8px;
}
.cvd-ini {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 112px;
  gap: 12px;
  align-items: start;
  padding: 7px 0;
}
.cvd-ini + .cvd-ini { border-top: 1px dotted var(--line-soft, #E1DFDB); }
.cvd-ini-rank {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: 14px;
  color: #953B0F;
}
.cvd-ini-name { font-size: 13.5px; color: var(--ink, #0D3D2D); line-height: 1.45; }
.cvd-ini-meta { font-size: 11px; color: var(--muted, #4A4A48); margin-top: 3px; line-height: 1.4; }
.cvd-ini-band { justify-self: end; }

/* Der Bandchip lag bisher in clubs-04-modules.css und damit nur in Clubs
   vor. Leagues und Events zeigten stattdessen eine gefuellte Pille mit
   Inline-Farbe. Hier steht er einmal fuer alle drei. */
.cvd-ini-band .pt-band {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  white-space: nowrap;
}
.cvd-ini-band .pt-band.go { color: #15661D; }
.cvd-ini-band .pt-band.fast { color: #953B0F; }
.cvd-ini-band .pt-band.consider { color: var(--coral-dark, #B4551D); }
.cvd-ini-band .pt-band.park { color: var(--muted, #4A4A48); }

.cvd-note {
  font-size: 12px;
  color: var(--muted, #4A4A48);
  line-height: 1.55;
  background: var(--white, #FFFDF9);
  border: 1px dashed var(--line-soft, #E1DFDB);
  border-radius: var(--r-md, 3px);
  padding: 10px 12px;
}
.cvd-foot {
  font-size: 12px;
  color: var(--muted, #4A4A48);
  line-height: 1.6;
  margin-top: 12px;
}

/* ── Handy ───────────────────────────────────────────────────────── */
@media (max-width: 860px) {
  .cvd-dom-sum {
    grid-template-columns: 32px minmax(0, 1fr) 104px;
    gap: 10px;
    row-gap: 10px;
    padding: 13px 14px;
  }
  .cvd-meter { grid-column: 2 / -1; }
  /* Ohne diese Regel landet der Zaehlchip in der schmalen Indexspalte. */
  .cvd-count { grid-column: 2 / -1; justify-self: start; }
  /* Eigene Zeile, sonst haengt das erste Wort der Unterzeile am Domaenennamen. */
  .cvd-name-sub { display: block; margin-left: 0; margin-top: 2px; }
  .cvd-toggle { display: none; }
  .cvd-body { padding: 14px; }
  .cvd-ini { grid-template-columns: 34px minmax(0, 1fr); }
  .cvd-ini-band { grid-column: 2; justify-self: start; margin-top: 4px; }
  /* 2026-08-04 · Die Reihe ist ein Gitter — auf dem Handy eine Spalte. */
  .cvd-summary { grid-template-columns: 1fr; }
}
