/* Styles für Kreis-Themenseiten */

/* Basisstil-Erweiterungen */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* Timeline-Styling für die Pi-Geschichte */
.timeline {
  position: relative;
  max-width: 1200px;
  margin: 40px auto;
  padding: 20px 0;
}

.timeline::before {
  content: '';
  position: absolute;
  height: 100%;
  width: 4px;
  background-color: #3498db;
  left: 50px;
  top: 0;
  border-radius: 2px;
}

.timeline-item {
  position: relative;
  margin-bottom: 50px;
  padding-left: 100px;
  transition: transform 0.3s, opacity 0.3s;
  opacity: 0;
  transform: translateX(20px);
}

.timeline-item.fade-in {
  opacity: 1;
  transform: translateX(0);
}

.timeline-date {
  position: absolute;
  left: 0;
  top: 0;
  width: 100px;
  padding: 8px 10px;
  background-color: #3498db;
  color: white;
  border-radius: 4px;
  text-align: center;
  font-weight: bold;
  font-size: 0.9rem;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.timeline-content {
  background-color: #fff;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  border-left: 4px solid #3498db;
}

.timeline-content h3 {
  margin-top: 0;
  color: #1e3c72;
  margin-bottom: 10px;
}

.fact-box {
  background-color: #e8f4fd;
  border-radius: 8px;
  padding: 20px;
  margin: 30px 0;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
  border-top: 5px solid #9b59b6;
}

.fact-box h3 {
  color: #9b59b6;
  margin-top: 0;
  margin-bottom: 15px;
}

.formula-box {
  background-color: #f0f7ff;
  border-radius: 8px;
  padding: 20px;
  margin: 30px 0;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.formula-box h3 {
  color: #1e3c72;
  margin-top: 0;
  margin-bottom: 15px;
}

.approximation-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 0.95rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  overflow: hidden;
}

.approximation-table th {
  background-color: #3498db;
  color: white;
  padding: 12px 15px;
  text-align: left;
  font-weight: bold;
}

.approximation-table td {
  padding: 10px 15px;
  border-bottom: 1px solid #e0e0e0;
}

.approximation-table tr:nth-child(even) {
  background-color: #f5f9ff;
}

.approximation-table tr:hover {
  background-color: #e8f4fd;
}

.approximation-table tr:last-child td {
  border-bottom: none;
}

.interactive-element {
  background-color: #fff;
  border-radius: 8px;
  padding: 20px;
  margin: 30px 0;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  border-top: 5px solid #f39c12;
}

.interactive-element h3 {
  color: #f39c12;
  margin-top: 0;
  margin-bottom: 15px;
}

/* Mobile Anpassungen für die Timeline */
@media (max-width: 767px) {
  .timeline::before {
    left: 20px;
  }
  
  .timeline-item {
    padding-left: 60px;
  }
  
  .timeline-date {
    width: 80px;
    left: -60px;
    font-size: 0.8rem;
    padding: 6px 8px;
  }
  
  .timeline-content {
    padding: 15px;
  }
  
  .approximation-table {
    font-size: 0.8rem;
  }
  
  .approximation-table th,
  .approximation-table td {
    padding: 8px 10px;
  }
}

/* Anpassungen für sehr kleine Bildschirme */
@media (max-width: 480px) {
  .timeline::before {
    left: 15px;
  }
  
  .timeline-item {
    padding-left: 45px;
  }
  
  .timeline-date {
    position: relative;
    left: -45px;
    width: 100%;
    margin-bottom: 10px;
    font-size: 0.75rem;
  }
  
  .approximation-table {
    font-size: 0.7rem;
  }
  
  .approximation-table th,
  .approximation-table td {
    padding: 6px 8px;
  }
}

/* Styles für Anwendungen von Kreissektoren und Kreissegmenten */
.application-container {
  margin: 30px 0;
}

.application-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.application-item {
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.application-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.application-icon {
  background-color: #3498db;
  color: white;
  padding: 20px;
  text-align: center;
  font-size: 2rem;
}

.application-item:nth-child(2) .application-icon {
  background-color: #e74c3c;
}

.application-item:nth-child(3) .application-icon {
  background-color: #2ecc71;
}

.application-item:nth-child(4) .application-icon {
  background-color: #f39c12;
}

.application-content {
  padding: 15px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.application-content h4 {
  margin-top: 0;
  color: #333;
  margin-bottom: 10px;
}

.application-content p {
  margin-bottom: 0;
  font-size: 0.95rem;
  flex-grow: 1;
}

/* Responsive Anpassungen für die Anwendungen */
@media (max-width: 767px) {
  .application-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .application-icon {
    padding: 15px;
    font-size: 1.5rem;
  }
  
  .application-content {
    padding: 12px;
  }
  
  .application-content h4 {
    font-size: 1.1rem;
  }
  
  .application-content p {
    font-size: 0.9rem;
  }
}

/* Verbessertes Berührungs-Feedback für mobile Geräte */
@media (pointer: coarse) {
  .quiz-options label,
  .check-answer,
  a {
    min-height: 44px;
    display: flex;
    align-items: center;
  }
  
  .quiz-options input[type="radio"] {
    min-width: 20px;
    min-height: 20px;
  }
}

.section {
  margin-bottom: 40px;
}

/* Spezielle Stil-Elemente für Kreise */
.bg-element.circle-element-1 {
  font-size: 8rem;
  opacity: 0.1;
  position: absolute;
  top: 20px;
  left: 10%;
  font-family: 'Cambria Math', serif;
  color: #1e3c72;
}

.bg-element.circle-element-2 {
  font-size: 2rem;
  opacity: 0.1;
  position: absolute;
  bottom: 20px;
  right: 10%;
  font-family: 'Cambria Math', serif;
  color: #2a5298;
}

.bg-element.circle-element-3 {
  font-size: 6rem;
  opacity: 0.1;
  position: absolute;
  top: 40%;
  right: 15%;
  font-family: 'Cambria Math', serif;
  color: #3498db;
}

/* Erklärungsboxen */
.explanation-box {
  background-color: #f5f7fa;
  border-left: 5px solid #3498db;
  padding: 20px;
  margin: 25px 0;
  border-radius: 0 8px 8px 0;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.explanation-box h3 {
  color: #2a5298;
  margin-top: 0;
  margin-bottom: 15px;
}

.explanation-box ul {
  padding-left: 20px;
  margin-bottom: 0;
}

.explanation-box li {
  margin-bottom: 8px;
}

/* Formelableitungen */
.formula-derivation {
  background-color: #f0f7ff;
  padding: 20px;
  margin: 25px 0;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.formula-derivation h3 {
  color: #1e3c72;
  margin-top: 0;
  margin-bottom: 15px;
}

.formula {
  background-color: #fff;
  padding: 15px;
  margin: 15px 0;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  overflow-x: auto; /* Formel-Überlauf vermeiden */
}

.highlighted-result {
  background-color: #e8f4fd;
  border: 1px solid #c2e5ff;
  color: #1e3c72;
  padding: 15px;
  margin: 15px 0;
  border-radius: 8px;
  text-align: center;
  font-weight: bold;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

/* Beispielboxen */
.example-box {
  background-color: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 20px;
  margin: 25px 0;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.example-box h3 {
  color: #e74c3c;
  margin-top: 0;
  margin-bottom: 15px;
  border-bottom: 2px solid #f5f5f5;
  padding-bottom: 8px;
}

.solution-steps {
  background-color: #f9f9f9;
  padding: 15px;
  margin-top: 15px;
  border-radius: 8px;
  border-left: 3px solid #e74c3c;
}

.solution-steps h4 {
  color: #e74c3c;
  margin-top: 0;
  margin-bottom: 10px;
}

/* Interaktive Übungen */
.interactive-exercise {
  margin: 30px 0;
  background-color: #f8f9fa;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.interactive-exercise h3 {
  color: #2a5298;
  margin-top: 0;
  margin-bottom: 20px;
}

.quiz-container {
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.quiz-question {
  padding: 20px;
  border-bottom: 1px solid #f0f0f0;
}

.quiz-question:last-child {
  border-bottom: none;
}

.quiz-options {
  margin: 15px 0;
}

.quiz-options label {
  display: block;
  padding: 10px;
  margin-bottom: 5px;
  background-color: #f8f9fa;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.quiz-options label:hover {
  background-color: #e8f0fe;
}

.quiz-options input[type="radio"] {
  margin-right: 10px;
}

.check-answer {
  background-color: #4285f4;
  color: white;
  border: none;
  padding: 10px 15px;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.check-answer:hover {
  background-color: #3367d6;
}

.feedback {
  margin-top: 10px;
  padding: 10px;
  border-radius: 5px;
  display: none;
}

.feedback.warning {
  display: block;
  background-color: #fff3cd;
  border: 1px solid #ffeeba;
  color: #856404;
}

.feedback.correct {
  display: block;
  background-color: #d4edda;
  border: 1px solid #c3e6cb;
  color: #155724;
}

.feedback.incorrect {
  display: block;
  background-color: #f8d7da;
  border: 1px solid #f5c6cb;
  color: #721c24;
}

/* Nächste Schritte Box */
.next-steps-box {
  background-color: #e8f5e9;
  border-left: 5px solid #4caf50;
  padding: 20px;
  margin: 25px 0;
  border-radius: 0 8px 8px 0;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.next-steps-box h3 {
  color: #2e7d32;
  margin-top: 0;
  margin-bottom: 15px;
}

.next-steps-box ul {
  padding-left: 20px;
  margin-bottom: 0;
}

.next-steps-box li {
  margin-bottom: 8px;
}

.next-steps-box a {
  color: #2e7d32;
  text-decoration: none;
  transition: color 0.2s;
}

.next-steps-box a:hover {
  color: #1b5e20;
  text-decoration: underline;
}

/* GeoGebra Container - Minimale Anpassung */
.geogebra-container {
  margin: 25px 0;
  width: 100%;
  text-align: center;
  position: relative;
  overflow: hidden;
  padding-bottom: 20px;
  background-color: #f5f5f5;
  border-radius: 8px;
}

.geogebra-container iframe {
  display: block;
  margin: 0 auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  max-width: 100%;
}

/* Aufgabenstil */
.exercise-container {
  background-color: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 20px;
  margin: 25px 0;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.exercise-container h3 {
  color: #2a5298;
  margin-top: 0;
  margin-bottom: 15px;
  border-bottom: 2px solid #f5f5f5;
  padding-bottom: 8px;
}

.exercise-container .hint {
  background-color: #fff3cd;
  border-left: 3px solid #ffc107;
  padding: 10px 15px;
  margin: 15px 0;
  border-radius: 0 8px 8px 0;
}

.exercise-container .hint h4 {
  color: #856404;
  margin-top: 0;
  margin-bottom: 5px;
}

/* Beweisführungsschritte */
.proof-steps {
  counter-reset: step-counter;
  list-style-type: none;
  padding-left: 0;
}

.proof-steps li {
  position: relative;
  padding-left: 40px;
  margin-bottom: 20px;
  background-color: #f8f9fa;
  padding: 15px 15px 15px 50px;
  border-radius: 8px;
}

.proof-steps li:before {
  content: counter(step-counter);
  counter-increment: step-counter;
  position: absolute;
  left: 15px;
  top: 15px;
  width: 25px;
  height: 25px;
  background-color: #4285f4;
  color: white;
  border-radius: 50%;
  text-align: center;
  line-height: 25px;
  font-weight: bold;
}

/* Schrittweises Einblenden */
.fade-in {
  opacity: 0;
  animation: fadeIn 0.8s forwards;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Mobile Anpassungen - Vorsichtig angepasst */
@media (max-width: 767px) {
  .container {
    padding: 15px;
  }
  
  .example-box, .explanation-box, .formula-derivation, .interactive-exercise, .next-steps-box {
    padding: 15px;
    margin: 15px 0;
  }
  
  .quiz-options label {
    padding: 12px 10px;
    font-size: 15px;
  }
  
  .formula {
    padding: 10px;
    overflow-x: auto;
    font-size: 0.9em;
  }
  
  .bg-element.circle-element-1,
  .bg-element.circle-element-2,
  .bg-element.circle-element-3 {
    display: none;
  }
}

@media (max-width: 480px) {
  .container h2 {
    font-size: 1.5rem;
  }
  
  .container h3 {
    font-size: 1.3rem;
  }
  
  .quiz-options label {
    font-size: 14px;
  }
  
  .check-answer {
    width: 100%;
    padding: 12px;
  }
}

/* Animation-Titel-Stil */
.animation-title {
  margin-top: 30px;
  margin-bottom: 20px;
  text-align: left;
}

.animation-title h2 {
  color: #1e3c72;
  margin-bottom: 10px;
  font-size: 1.6rem;
}

.animation-title p {
  color: #555;
  max-width: 800px;
}

/* Verbesserte GeoGebra-Container Styles */
.geogebra-container {
  margin: 25px 0;
  width: 100%;
  position: relative;
  background-color: #f5f5f5;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.geogebra-iframe {
  display: block;
  width: 100%;
  border: none;
  margin: 0 auto;
  border-radius: 8px;
  background-color: white;
  box-sizing: border-box;
}

/* Messwerte-Tabellen Stil */
.measurement-table-container {
  margin: 30px 0;
  background-color: #f8f9fa;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.measurement-table-container h3 {
  color: #2a5298;
  margin-top: 0;
  margin-bottom: 20px;
}

.table-responsive {
  overflow-x: auto;
}

.measurement-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 15px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  overflow: hidden;
  background-color: white;
}

.measurement-table th {
  background-color: #3498db;
  color: white;
  padding: 12px 15px;
  text-align: left;
  font-weight: bold;
}

.measurement-table td {
  padding: 10px 15px;
  border-bottom: 1px solid #e0e0e0;
}

.measurement-table tr:last-child td {
  border-bottom: none;
}

.measurement-table input[type="number"] {
  width: calc(100% - 10px);
  padding: 8px 5px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.95rem;
  transition: border-color 0.2s;
}

.measurement-table input[type="number"]:focus {
  border-color: #3498db;
  outline: none;
  box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.measurement-table td.ratio {
  font-weight: bold;
  color: #1e3c72;
}

.table-hint {
  margin-top: 15px;
  padding: 10px 15px;
  background-color: #e8f4fd;
  border-radius: 6px;
  border-left: 4px solid #3498db;
}

.table-hint p {
  margin: 0;
  color: #2a5298;
}

/* Mobile Anpassungen */
@media (max-width: 767px) {
  .animation-title h2 {
    font-size: 1.4rem;
  }
  
  .measurement-table th,
  .measurement-table td {
    padding: 8px 10px;
    font-size: 0.9rem;
  }
  
  .measurement-table-container {
    padding: 15px;
  }
  
  .measurement-table input[type="number"] {
    font-size: 16px; /* Verhindert das Zoomen auf iOS bei Fokus */
    padding: 8px 4px;
  }
}

@media (max-width: 480px) {
  .animation-title h2 {
    font-size: 1.3rem;
  }
  
  .measurement-table th {
    font-size: 0.85rem;
  }
  
  .measurement-table td {
    padding: 8px 5px;
  }
  
  .table-hint p {
    font-size: 0.9rem;
  }
}

.applet_scaler {
    width: 100% !important;
    height: 550px !important;
    transform: none !important;
    zoom: 1.15 !important;
}