/* CyberDesigner Kundenzufriedenheit: Footer-Widget (alle Seiten) + Startseiten-Gauge. Daten: /kundenkonto/score.php (nur Aggregat). */

/* ---------- Footer-Widget ---------- */
.cdx-footer .cdk-fscore {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
  height: 32px;
  padding: 0 .75rem 0 .35rem;
  border: 1px solid rgba(94, 200, 255, .18);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(61, 158, 255, .10), rgba(255, 255, 255, .02) 55%, rgba(94, 200, 255, .06));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 0 18px rgba(61, 158, 255, .10);
  color: var(--cdx-muted, #b0bccb);
  font: 500 .8rem/1 var(--cdx-font, sans-serif);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  transition: border-color .2s ease, color .2s ease, box-shadow .2s ease;
}
.cdx-footer .cdk-fscore:hover { color: #fff; border-color: rgba(94, 200, 255, .45); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 0 22px rgba(61, 158, 255, .22); }
.cdx-footer .cdk-fscore:focus-visible { outline: 2px solid var(--cdx-cyan, #5ec8ff); outline-offset: 2px; }
.cdk-fscore__ring { flex: 0 0 22px; width: 22px; height: 22px; transform: rotate(-90deg); overflow: visible; }
.cdk-fscore__track { fill: none; stroke: rgba(242, 244, 247, .12); stroke-width: 3.5; }
.cdk-fscore__arc { fill: none; stroke: url(#cdk-fg); stroke-width: 3.5; stroke-linecap: round; filter: drop-shadow(0 0 3px rgba(94, 200, 255, .6)); transition: stroke-dasharray 1.2s cubic-bezier(.22, 1, .36, 1); }
.cdk-fscore__text { overflow: hidden; text-overflow: ellipsis; letter-spacing: .01em; }
.cdk-fscore__text b { color: var(--cdx-text, #f2f4f7); font-weight: 700; font-variant-numeric: tabular-nums; }
.cdk-fscore.is-empty .cdk-fscore__arc { stroke-dasharray: 18 100; }
@media (prefers-reduced-motion: no-preference) {
  .cdk-fscore.is-empty .cdk-fscore__ring { animation: cdk-spin 6s linear infinite; }
  .cdk-fscore::after {
    content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
    background: linear-gradient(105deg, transparent 35%, rgba(225, 243, 255, .16) 50%, transparent 65%);
    background-size: 250% 100%; background-position: 150% 0; animation: cdk-sheen 7s ease-in-out 1.5s infinite;
  }
}
@keyframes cdk-spin { from { transform: rotate(-90deg); } to { transform: rotate(270deg); } }
@keyframes cdk-sheen { 0%, 70% { background-position: 150% 0; } 100% { background-position: -50% 0; } }

/* Desktop: eine Zeile, Titel weicht per Ellipsis */
body.cdx .cdx-footer__bar .cdk-fscore { margin-left: auto; }
body.cdx .cdx-footer__bar .cdk-fscore + nav { margin-left: 0; }

/* Tablet (601–900px): Widget rechts in Zeile 1 neben dem Titel, Footer-Höhe unverändert */
@media (max-width: 900px) {
  body.cdx .cdx-footer__bar .cdk-fscore { height: 28px; font-size: .76rem; }
  body.cdx .cdx-footer__bar .cdk-fscore + nav { margin-left: 0; }
}
/* Mobil (≤600px): genau eine kompakte Zusatzzeile (+26px, Ziel ≥24px) */
@media (max-width: 600px) {
  :root:root { --cdx-footer-h: calc(106px + env(safe-area-inset-bottom, 0px)); }
  body.cdx .cdx-footer__bar .cdk-fscore {
    order: 3; flex: 1 0 100%; margin: 0; height: 24px; padding: 0; gap: .45rem; font-size: .74rem;
    border: 0; border-radius: 0; background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none;
  }
  body.cdx .cdx-footer__bar .cdk-fscore::after { display: none; }
  body.cdx .cdx-footer__bar nav { order: 4; }
  .cdk-fscore__ring { flex-basis: 16px; width: 16px; height: 16px; }
}
@media (max-width: 380px) { .cdk-fscore__lbl { display: none; } }

/* ---------- Startseite: Premium-Gauge ---------- */
.cdk-hscore {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 1rem 1.15rem;
  margin-top: 1.4rem;
  padding: 1rem 1.15rem;
  min-height: 108px;
  box-sizing: border-box;
  border: 1px solid rgba(94, 200, 255, .2);
  border-radius: 18px;
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(61, 158, 255, .16), transparent 55%),
    radial-gradient(90% 120% at 100% 100%, rgba(140, 110, 255, .10), transparent 60%),
    linear-gradient(180deg, rgba(22, 29, 40, .78), rgba(11, 14, 20, .72));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .07), 0 18px 50px rgba(0, 0, 0, .35), 0 0 0 1px rgba(255, 255, 255, .02);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  overflow: hidden;
  color: var(--cdx-text, #f2f4f7);
  max-width: 34rem;
}
.cdk-hscore::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; padding: 1px;
  background: linear-gradient(135deg, rgba(94, 200, 255, .55), rgba(61, 158, 255, .05) 40%, rgba(160, 120, 255, .35));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: .7;
}
.cdk-hscore__gauge { position: relative; width: 84px; height: 84px; }
.cdk-hscore__gauge svg { width: 84px; height: 84px; transform: rotate(-90deg); overflow: visible; }
.cdk-hscore__track { fill: none; stroke: rgba(242, 244, 247, .09); stroke-width: 7; }
.cdk-hscore__arc { fill: none; stroke: url(#cdk-hg); stroke-width: 7; stroke-linecap: round; stroke-dasharray: 0 100; filter: drop-shadow(0 0 6px rgba(94, 200, 255, .55)); transition: stroke-dasharray 1.6s cubic-bezier(.22, 1, .36, 1); }
.cdk-hscore__glass { fill: rgba(255, 255, 255, .035); stroke: rgba(255, 255, 255, .08); stroke-width: .6; }
.cdk-hscore__val {
  position: absolute; inset: 0; display: grid; place-items: center; text-align: center;
  font: 800 1.45rem/1 var(--cdx-display, sans-serif); font-variant-numeric: tabular-nums;
  background: linear-gradient(180deg, #fff, #9fd8ff); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.cdk-hscore__val small { display: block; margin-top: .15rem; font: 600 .62rem/1 var(--cdx-font, sans-serif); letter-spacing: .08em; color: var(--cdx-faint, #a8b4c4); -webkit-text-fill-color: var(--cdx-faint, #a8b4c4); }
.cdk-hscore__kicker { margin: 0; font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--cdx-cyan, #5ec8ff); }
.cdk-hscore__headline { margin: .3rem 0 0; font: 700 1.05rem/1.3 var(--cdx-display, sans-serif); color: var(--cdx-text, #f2f4f7); }
.cdk-hscore__desc { margin: .3rem 0 0; font-size: .86rem; line-height: 1.45; color: var(--cdx-muted, #b0bccb); }
.cdk-hscore__link { display: inline-flex; align-items: center; min-height: 44px; margin: .05rem 0 -.6rem; color: var(--cdx-cyan, #5ec8ff); font-size: .86rem; font-weight: 600; text-decoration: none; }
.cdk-hscore__link:hover { color: #fff; }
.cdk-hscore__link:focus-visible { outline: 2px solid var(--cdx-cyan, #5ec8ff); outline-offset: 2px; border-radius: 6px; }
.cdk-hscore__link.is-care::before { content: ""; width: 8px; height: 8px; margin-right: .5rem; border-radius: 50%; background: var(--cdx-good, #3ecf8e); box-shadow: 0 0 0 0 rgba(62, 207, 142, .6); }
.cdk-hscore.is-empty .cdk-hscore__arc { stroke-dasharray: 22 100; opacity: .85; }
.cdk-hscore.is-empty .cdk-hscore__val { font-size: 1.5rem; }
.cdk-hscore__soon { font-style: normal; background: linear-gradient(90deg, #fff, #9fd8ff 55%, #c8b5ff); -webkit-background-clip: text; background-clip: text; color: transparent; }
@media (prefers-reduced-motion: no-preference) {
  .cdk-hscore.is-empty .cdk-hscore__gauge svg { animation: cdk-spin 8s linear infinite; }
  .cdk-hscore__link.is-care::before { animation: cdk-pulse 2.4s ease-out infinite; }
  .cdk-hscore::after {
    content: ""; position: absolute; inset: -40% -10%; pointer-events: none;
    background: linear-gradient(110deg, transparent 40%, rgba(225, 243, 255, .07) 50%, transparent 60%);
    transform: translateX(-60%); animation: cdk-glass 9s ease-in-out 2s infinite;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cdk-hscore__arc, .cdk-fscore__arc { transition: none; }
}
@keyframes cdk-pulse { 0% { box-shadow: 0 0 0 0 rgba(62, 207, 142, .55); } 80%, 100% { box-shadow: 0 0 0 9px rgba(62, 207, 142, 0); } }
@keyframes cdk-glass { 0%, 65% { transform: translateX(-60%); } 100% { transform: translateX(60%); } }
@media (max-width: 900px) { .cdk-hscore { max-width: none; } }
@media (max-width: 380px) {
  .cdk-hscore { grid-template-columns: 1fr; justify-items: start; gap: .6rem; padding: .9rem 1rem; }
  .cdk-hscore__gauge, .cdk-hscore__gauge svg { width: 72px; height: 72px; }
}

/* ---- Empty-state: compact discreet pill (Wow ohne Dominanz) ---- */
.cdx-footer .cdk-fscore.is-empty {
  gap: .4rem;
  height: 28px;
  padding: 0 .65rem 0 .3rem;
  max-width: min(100%, 17.5rem);
  border-color: rgba(94, 200, 255, .12);
  background: linear-gradient(135deg, rgba(61, 158, 255, .06), rgba(255, 255, 255, .015) 55%, rgba(94, 200, 255, .03));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04), 0 0 10px rgba(61, 158, 255, .06);
  color: rgba(176, 188, 203, .78);
  font-weight: 500;
  font-size: .72rem;
}
.cdx-footer .cdk-fscore.is-empty .cdk-fscore__ring { flex-basis: 16px; width: 16px; height: 16px; opacity: .85; }
.cdx-footer .cdk-fscore.is-empty .cdk-fscore__text {
  display: inline !important;
  opacity: .82;
  letter-spacing: .005em;
  font-size: .72rem;
  font-weight: 500;
}
.cdx-footer .cdk-fscore.is-empty:hover {
  color: rgba(220, 230, 242, .92);
  border-color: rgba(94, 200, 255, .28);
}
@media (max-width: 600px) {
  .cdx-footer .cdk-fscore.is-empty {
    height: 22px; font-size: .68rem; padding: 0; gap: .35rem;
    border: 0; background: none; box-shadow: none; max-width: 100%;
    color: rgba(176, 188, 203, .72);
  }
  .cdx-footer .cdk-fscore.is-empty .cdk-fscore__ring { flex-basis: 14px; width: 14px; height: 14px; }
}

/* 2026-11-05 bewertung-pill: leerer Score als dezente, zentrierte Premium-Pill */
.h1s__score {
  grid-column: 1 / -1;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin: 0.15rem 0 0.35rem;
  padding: 0;
  box-sizing: border-box;
}
.h1s__score .cdk-hscore {
  margin-top: 0;
}
/* Empty → eine Zeile, mittig, Glas-Pill, kein Dominieren */
.cdk-hscore.is-empty {
  display: inline-flex !important;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  grid-template-columns: none !important;
  gap: 0.4rem;
  width: auto;
  max-width: min(100%, 16rem);
  min-height: 0 !important;
  margin: 0 auto;
  padding: 0.32rem 0.78rem 0.32rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 176, 210, 0.14);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.04), rgba(12, 18, 28, 0.42) 48%, rgba(94, 200, 255, 0.05));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 4px 14px rgba(0, 0, 0, 0.16);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  overflow: visible;
}
.cdk-hscore.is-empty::before {
  content: none !important;
  display: none !important;
}
.cdk-hscore.is-empty::after {
  content: none !important;
  display: none !important;
  animation: none !important;
}
.cdk-hscore.is-empty .cdk-hscore__gauge {
  display: none !important;
}
.cdk-hscore.is-empty > div:last-child {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: 0.35rem 0.55rem;
  min-width: 0;
  max-width: 100%;
}
.cdk-hscore.is-empty .cdk-hscore__kicker,
.cdk-hscore.is-empty .cdk-hscore__desc {
  display: none !important;
}
.cdk-hscore.is-empty .cdk-hscore__headline {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
  font: 500 0.72rem/1.2 var(--cdx-font, sans-serif);
  letter-spacing: 0.01em;
  color: rgba(176, 188, 203, 0.82);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cdk-hscore.is-empty .cdk-hscore__headline::before {
  content: "";
  flex: 0 0 auto;
  width: 0.7rem;
  height: 0.7rem;
  background: rgba(212, 196, 140, 0.72);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='%23000' d='M8 1.2l1.76 3.56 3.93.57-2.84 2.77.67 3.91L8 10.9l-3.52 1.85.67-3.91L2.3 5.33l3.93-.57L8 1.2z'/%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 16 16'%3E%3Cpath fill='%23000' d='M8 1.2l1.76 3.56 3.93.57-2.84 2.77.67 3.91L8 10.9l-3.52 1.85.67-3.91L2.3 5.33l3.93-.57L8 1.2z'/%3E%3C/svg%3E") center / contain no-repeat;
  opacity: 0.85;
}
.cdk-hscore.is-empty .cdk-hscore__soon {
  font-style: normal;
  font-weight: 500;
  background: none !important;
  -webkit-background-clip: border-box !important;
  background-clip: border-box !important;
  color: rgba(186, 198, 214, 0.88) !important;
  -webkit-text-fill-color: rgba(186, 198, 214, 0.88) !important;
}
.cdk-hscore.is-empty .cdk-hscore__link {
  margin: 0;
  min-height: 0;
  padding: 0;
  font-size: 0.68rem;
  font-weight: 560;
  letter-spacing: 0.01em;
  opacity: 0.72;
  color: rgba(148, 188, 220, 0.9);
  white-space: nowrap;
  text-decoration: none;
}
.cdk-hscore.is-empty .cdk-hscore__link:hover,
.cdk-hscore.is-empty .cdk-hscore__link:focus-visible {
  opacity: 1;
  color: #e8f4ff;
}
.cdk-hscore.is-empty .cdk-hscore__link.is-care::before {
  width: 6px;
  height: 6px;
  margin-right: 0.35rem;
}
/* Filled score stays a card, still centered in the rail */
.h1s__score .cdk-hscore:not(.is-empty) {
  width: min(100%, 28rem);
  margin-left: auto;
  margin-right: auto;
}
@media (max-width: 520px) {
  .cdk-hscore.is-empty {
    width: auto;
    max-width: min(100%, 13.5rem);
    margin-left: auto;
    margin-right: auto;
    padding: 0.28rem 0.7rem 0.28rem 0.55rem;
    gap: 0.25rem;
  }
  .cdk-hscore.is-empty > div:last-child {
    flex-wrap: wrap;
    justify-content: center;
    row-gap: 0.12rem;
    max-width: 100%;
  }
  .cdk-hscore.is-empty .cdk-hscore__headline {
    font-size: 0.68rem;
    white-space: normal;
    text-align: center;
  }
  .cdk-hscore.is-empty .cdk-hscore__link {
    font-size: 0.64rem;
  }
}
/* footer-neu: keep empty pill compact on phones up to 900px */
@media (max-width: 900px) {
  .h1s__score {
    display: flex;
    justify-content: center;
    width: 100%;
  }
  .cdk-hscore.is-empty {
    width: auto;
    max-width: min(100%, 13.75rem);
    margin-left: auto;
    margin-right: auto;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .cdk-hscore.is-empty .cdk-hscore__gauge svg { animation: none !important; }
}

