/* Basis-Stile */
#pdfButton {
	background-color: #CD0A1E;
	color: white;
	font-weight: 700;
  padding: 20px;
}

#app h1 {
  color: #ffffff;
  max-width: 100%;
  font-size: 1.5em;
  line-height: 1.2;
}

#app h3 {
  margin-bottom: 0;
}

#app p {
  margin-bottom: 1rem;
}

#app .button {
  margin-top: 0;
}

#app .image__td {
  line-height: 0;
}

#app .ans_option {
  position: relative;
}

#app .ans_option:hover:after {
  content: attr(data-title);
  background-color: rgba(0, 0, 0, 0.8);
  color: #fff;
  padding: 15px;
  border-radius: 5px;
  position: absolute;
  bottom: 100%;
  left: 0%;
  transform: translateX(-50%);
  white-space: wrap;
  z-index: 1;
  background-image: url('/fileadmin/scripts/images/IMG_0450.png');
  background-size: 20px 20px;
  background-repeat: no-repeat;
  background-position: left center;
  width: 300px;
  text-align: left;
}

#app .ans_option:hover:after {
  padding-left: 25px;
}

#app .ans_option:not([data-title]):after {
  display: none !important;
  content: none !important;
}

#app .ans_option[data-title=""]:after {
  display: none !important;
  content: none !important;
}

#app .app-container {
  font-family: Arial, Helvetica, sans-serif;
  margin: 0 auto;
  width: 1200px;
  font-weight: normal;
}

#app .custom-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1em;
  border-radius: 1em;
}

#app .main-title {
  font-size: 3em;
  font-weight: bold;
}

#app .readiness-header {
  background-color: #CD0A1E;
  color: white;
  padding: 30px;
  margin-top: 15px;
  border-radius: 20px 20px 0 0;
}

#app .readiness-header .main-title {
  font-size: 3em;
  font-weight: bold;
}

#app .custom-th,
#app .custom-td {
  border: thin solid #ccc;
  padding: 0.5em;
  text-align: left;
  width: 100%;
}

#app .custom-th {
  background-color: #eee;
  font-size: 1.5em;
  color: #cd0a1e;
}

#app .custom-td {
  font-size: 0.85em;
}

#app .custom-td b {
  font-weight: bold;
  color: red;
}

#app .ans_option {
  width: 5em;
  text-align: center;
  cursor: pointer;
}

#app .ans_option:hover {
  background-color: #ddd;
}

#app .ans_option.active {
  background-color: #CD0A1E;
  color: white;
  font-weight: 700;
}

#app #ergebnis {
  max-width: 45rem;
  margin: 1em auto 1em;
  border: thin solid #ccc;
  border-radius: 2em;
}

/* Zebratabelle-Stil */
#app .custom-table tbody tr:nth-child(odd) {
  background-color: #f9f9f9;
}

#app .custom-table tbody tr:nth-child(even) {
  background-color: #fff;
}

/* Beschreibungstext kleiner machen */
#app .beschreibung {
  font-size: 0.85em;
}

#app .questionnaire {
  border-radius: 8px;
}

#app .frage {
  font-weight: bold;
}

#app .summary-wrapper {
  background-color: #eee;
  border-bottom: thin solid #ccc;
  border-left: thin solid #ccc;
  border-right: thin solid #ccc;
  margin-bottom: 50px;
}

#app .summary {
  margin-top: 10px;
  margin-bottom: 50px;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  background-color: #f9f9f9;
}

#app .summary .summary-title {
  font-size: 2em;
  font-weight: bold;
}

#app .summary .summary-subtitle {
  font-size: 1em;
  padding-bottom: 10px;
}

#app .summary .summary-list {
  list-style-type: none;
}

#app .summary .summary-list-item {
  padding: 10px;
}

#app .hints-container h3 {
  font-size: 1.2em;
}

#app .radarchart-container {
  margin: 0;
  padding: 0;
  max-width: 600px;
  max-height: 600px;
  margin: 0 auto;
  width: 100%;
  height: auto;
}

#app .canvas__wrap {
  min-width: 100%;
}

#app .radar-chart {
  width: 100%;
  height: auto;
  display: block;
  max-height: 800px;
  margin: auto;
}

#app .chartjs-tooltip {
  background-color: rgba(0, 0, 0, 0.8) !important;
  color: white !important;
  border-radius: 10px !important;
  padding: 10px !important;
  width: 500px;
  height: 500px;
}

#app .chartjs-tooltip .chartjs-tooltip-title {
  font-weight: bold !important;
  font-size: 14px !important;
}

#app .chartjs-tooltip .chartjs-tooltip-label {
  font-size: 12px !important;
}

#app .chartjs-tooltip .chartjs-tooltip-footer {
  font-size: 10px !important;
  color: lightgray !important;
}

#app img {
  width: 250px;
  height: 150px;
  /* UI Properties */
  background: linear-gradient(180deg, rgba(205, 10, 30, 0) 0%, rgba(205, 10, 30, 0) 35%, rgba(205, 10, 30, 0.75) 100%);
  opacity: 1;
}

#app .help-text {
  font-size: 0.8rem;
}

#app .conclusion-wrapper {
  background-color: #CD0A1E;
  color: white;
  border-radius: 0 0 20px 20px;
}

#app .conclusion-wrapper h2 {
  font-weight: bold;
  font-size: 2.5em;
}

#app .conclusion-wrapper .hint-button {
  font-size: 2em !important;
  box-shadow: 0 4px 0 rgba(69, 69, 69, .11);
  margin-top: 10px;
  margin-bottom: 10px;
}

#app .conclusion-wrapper .hint-button:hover {
  color: white;
  box-shadow: 0 4px 0 rgba(69, 69, 69, .11);
}

/* =============== SUBGROUP / ROWSPAN LAYOUT ============== */

/* Die linke Zelle mit Subgruppen-Name */
.subgroup-th-rowspan {
  background-color: #f7f7f7;   /* Heller Hintergrund */
  vertical-align: top;         /* Subgruppen-Text oben anlehnen */
  font-weight: bold;           /* Fett gedruckt */
  padding: 1em;                /* Etwas Innenabstand */
  border-right: 3px solid #cd0a1e; /* Dicke rote Linie rechts */
  width: 220px;                /* Feste Breite */
  min-width: 220px;            /* Immer gleich breit */
  box-sizing: border-box;
  white-space: normal;
}

/* Zeile mit der Frage (Index + 5 Antworten) */
.question-row {
  background-color: #fcfcfc;
}

/* Zeile mit der Beschreibung */
.description-row {
  background-color: #fefefe; 
  font-size: 0.85em; 
  color: #333;
}

/* Subgruppe-Name leicht eingerückt */
.subgroup-indent {
  padding-left: 1em;
}

/* Oberkategorie-Header (7 oder 6 Spalten) */
.group-header-th {
  background-color: #cd0a1e; 
  color: white; 
  font-size: 1.3em;
  padding: 0.5em 1em;
  text-align: left;
}
.score-scale {
  display: flex;
  width: 100%;
  height: 3rem;       /* Höhe der Balken */
  overflow: hidden;   /* falls der Text rausragt */
  margin-bottom: 1rem;
  border: 1px solid #ccc;  /* einfacher Rahmen */
  border-radius: 4px;
}

.scale-segment {
  flex: 1 1 auto;     /* alle Segmente teilen sich den Platz gleichmäßig */
  display: flex;      /* um das Text zentrieren zu können */
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #333;        /* Textfarbe */
  font-weight: bold;
  font-size: 0.9rem;
  padding: 0.5rem;
  box-sizing: border-box;
}

/* Beispielhafte Farben (kannst du nach Belieben anpassen) */
.scale-segment.neuling    { background-color: #dceeff; }
.scale-segment.amateur    { background-color: #bce5ff; }
.scale-segment.aufstrebend { background-color: #9adbf0; }
.scale-segment.anwender   { background-color: #74cde5; }
.scale-segment.vorreiter  { background-color: #4dbbd9; }

/* Wenn du die Breiten der Segmente exakt an die Score-Range anpassen willst, 
   kannst du statisch Prozentangaben nehmen. Beispiel: */
.scale-segment.neuling    { flex: 0 0 20.3%; }  /* (1.61 - 1.00) / 3.00 ≈ 20.3% */
.scale-segment.amateur    { flex: 0 0 20.3%; }
.scale-segment.aufstrebend{ flex: 0 0 20.3%; }
.scale-segment.anwender   { flex: 0 0 20.3%; }
.scale-segment.vorreiter  { flex: 0 0 17.3%; }  /* (4.00 - 3.48) / 3.00 ≈ 17.3% */

/* Du hast 7 Spalten in subgruppen-Layout, 6 Spalten in ohne-subgruppen.
   Wir können die border anpassen, damit es einheitlich wirkt */
.custom-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1em;
}

.custom-table th,
.custom-table td {
  border: 1px solid #ccc;
  padding: 0.5em;
}
/* für die Bilder */
.group-container {
  margin-bottom: 2rem;
}

.group-header-image {
  width: 100% !important;
  height: 240px !important;
  object-fit: cover;
  display: block;
  margin-bottom: 1rem;
}


/* Lieber nicht so viele Zebrastreifen mischen – 
   du kannst das auskommentieren, wenn du den Subgruppen-Hintergrund
   eindeutig haben willst. */

#fragebogenWrapper {
  max-height: 0; 
  overflow: hidden;
  transition: max-height 0.5s ease-out;
}

#fragebogenWrapper.ausgeklappt {
  max-height: 10000px; 
}

#zusammenfassungWrapper,
#conclusion {
  max-height: 0; 
  overflow: hidden;
  transition: max-height 0.5s ease-out;
}

#zusammenfassungWrapper.ausgeklappt,
#conclusion.ausgeklappt {
  max-height: 1000px; 
  padding: 20px;
}

#unternehmensDiv {
  margin: 20px;
}

#userDatenDiv {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 400px;
  margin: 0;
}

#userDatenDiv label {
  font-size: 1rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
  color: #333;
}

#userDatenDiv input {
  border: 1px solid black;
  border-radius: 16px;
  border-top-right-radius: 0;
  font-size: 1rem;
  line-height: 1.625rem;
  padding: 0.5rem 1rem;
  width: 100%;
  background: transparent;
  transition: border-color 0.3s ease;
}

#unternehmensDiv input:focus {
  outline: none;
  border-color: #007bff;
}

#unternehmensDiv button {
  display: inline-block;
  border-radius: 16px;
  border-top-right-radius: 0;
  border: 1px solid white;
  padding: 8px 32px;
  padding: 0.5rem 2rem;
  background: linear-gradient(to right, white 50%, transparent 50%);
  background-size: 200% 100%;
  background-position: right bottom;
  transition: all 0.3s ease-out;
  background: #CD0A1E;
  color: white;
}

#unternehmensDiv button:hover {
  background-color: white;
  color: black;
  border: 1px solid black;
}

#speicherDiv {
  display: none;
  margin: 50px;
}

#speicherButton {
  display: inline-block;
  border-radius: 16px;
  border-top-right-radius: 0;
  border: 1px solid white;
  padding: 0.5rem 2rem;
  background: linear-gradient(to right, white 50%, transparent 50%);
  background-size: 200% 100%;
  background-position: right bottom;
  transition: all 0.3s ease-out;
  background: #CD0A1E;
  color: white;
}

#speicherButton:hover {
  background-color: white;
  color: black;
  border: 1px solid black;
}

/* ============== NEUER BEREICH FÜR GLOBALE ERGEBNISSE ============== */

#globalLabel {
  margin-top: 100px; /* Zusätzlicher Abstand vorm globalen Label */
  margin-bottom: 100px !important;
  font-size: 2em;
  text-align: center;
  font-weight: bold;
  background: #cd0a1e;
  color: white;
  padding: 30px;
}

#globalRow {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  margin-top: 20px;
  margin-bottom: 100px;
}

#globalLeft {
  width: 48%;
}

#globalRight {
  width: 48%;
  background-color: #f0f0f0;
  padding: 10px;
  text-align: center;
  font-style: italic;
}

/* NUR DIE ÜBERSCHRIFTEN IN #scoreSummary ROT UND WEISS */
#scoreSummary h3 {
  background-color: #cd0a1e; /* roter Hintergrund */
  color: white !important;   /* weiße Schrift */
  padding: 10px;
  border-radius: 5px;
  margin-bottom: 10px;
}

/* Alle anderen Elemente in #scoreSummary bleiben unverändert (kein roter Hintergrund). */

/* Media Queries */
@media (max-width: 1200px) {
  #app .custom-th {
    font-size: 1.3em;
  }

  #app .custom-td {
    font-size: 0.8em;
  }

  #app .summary-title {
    font-size: 1.8em;
  }

  #app .summary-subtitle {
    font-size: 0.9em;
  }

  #app .main-title {
    font-size: 2.5em;
  }
}

@media (max-width: 992px) {
  #app .ans-option {
    width: 4em;
  }

  #app .summary-wrapper {
    padding: 15px;
  }

  #app .readiness-header {
    padding: 20px;
  }

  #app .readiness-header .main-title {
    font-size: 2em;
  }
}

@media (max-width: 768px) {
  #app .custom-th {
    font-size: 1.2em;
  }

  #app .custom-td {
    font-size: 0.75em;
  }

  #app .ans-option {
    width: 3.5em;
  }

  #app .main-title {
    font-size: 1.8em;
  }

  #app .radarchart-container {
    max-width: 100%;
    max-height: 100%;
  }

  #app .radar-chart {
    max-width: 768px;
    max-height: 400px;
  }
}

@media (max-width: 576px) {
  #app .custom-th {
    font-size: 1.1em;
  }

  #app .custom-td {
    font-size: 0.7em;
  }

  #app .ans_option {
    width: 3em;
  }

  #app .summary-wrapper {
    padding: 10px;
  }

  #app .readiness-header {
    padding: 15px;
  }

  #app .readiness-header .main-title {
    font-size: 1.5em;
  }

  #app .radarchart-container {
    max-width: 576px;
    max-height: auto;
  }

  #app .radar-chart {
    max-width: 576px;
    max-height: 400px;
  }
}

@media (max-width: 400px) {
  #app .custom-th {
    font-size: 1em;
  }

  #app .custom-td {
    font-size: 0.65em;
  }

  #app .ans-option {
    width: 2.5em;
  }

  #app .main-title {
    font-size: 1.3em;
  }

  #app .radarchart-container {
    max-width: 400px;
    max-height: 400px;
  }

  #app .radar-chart {
    max-width: 400px;
    max-height: 300px;
  }

  #app h1 {
    font-size: 2em;
    font-weight: bold;
  }
}
