@scope (#original-content) {

#geometric-series-calculator-section * {
  box-sizing: border-box;
}

#geometric-series-calculator-section h1 {
  font-size: 32px;
  font-weight: 800;
  color: #1a1a1a;
  margin-bottom: 15px;
  text-align: center;
  line-height: 1.3;
}

#geometric-series-calculator-section h2 {
  font-size: 24px;
  font-weight: 700;
  color: #2c3e50;
  margin-top: 35px;
  margin-bottom: 15px;
  border-bottom: 3px solid #8b5cf6;
  padding-bottom: 8px;
}

#geometric-series-calculator-section h3 {
  font-size: 20px;
  font-weight: 700;
  color: #34495e;
  margin-top: 25px;
  margin-bottom: 12px;
}

#geometric-series-calculator-section p {
  font-size: 16px;
  line-height: 1.7;
  color: #444;
  margin-bottom: 15px;
  font-weight: 500;
}

#geometric-series-calculator-section .author-date {
  text-align: center;
  font-size: 14px;
  color: #666;
  margin-bottom: 25px;
  font-weight: 600;
}

.gs-calculator-container {
  background: linear-gradient(135deg, #faf5ff 0%, #f3e8ff 100%);
  border: 2px solid #e9d5ff;
  border-radius: 12px;
  padding: 30px;
  margin: 25px 0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.gs-mode-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 25px;
  justify-content: center;
}

.gs-mode-btn {
  padding: 12px 20px;
  background-color: #ffffff;
  border: 2px solid #8b5cf6;
  border-radius: 8px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 700;
  color: #8b5cf6;
  transition: all 0.3s ease;
}

.gs-mode-btn:hover {
  background-color: #8b5cf6;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(139,92,246,0.3);
}

.gs-mode-btn.active {
  background-color: #8b5cf6;
  color: #ffffff;
  box-shadow: 0 4px 8px rgba(139,92,246,0.3);
}

.gs-input-group {
  margin-bottom: 20px;
}

.gs-input-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 700;
  color: #2c3e50;
  font-size: 15px;
}

.gs-input-group input {
  width: 100%;
  padding: 14px;
  border: 2px solid #bdc3c7;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  transition: border-color 0.3s ease;
  background-color: #ffffff;
}

.gs-input-group input:focus {
  outline: none;
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139,92,246,0.1);
}

.gs-two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.gs-calc-button {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.gs-calc-button:hover {
  background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(139,92,246,0.4);
}

.gs-results-container {
  margin-top: 25px;
  padding: 25px;
  background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
  border: 2px solid #3b82f6;
  border-radius: 10px;
  display: none;
}

.gs-results-container.show {
  display: block;
}

.gs-result-item {
  padding: 15px;
  margin-bottom: 12px;
  background-color: #ffffff;
  border-left: 5px solid #8b5cf6;
  border-radius: 6px;
  font-weight: 700;
  font-size: 16px;
  color: #2c3e50;
}

.gs-result-value {
  color: #7c3aed;
  font-size: 20px;
  font-weight: 800;
}

.gs-sequence-display {
  background-color: #ffffff;
  border: 2px solid #c7d2fe;
  border-radius: 8px;
  padding: 15px;
  margin-top: 15px;
  max-height: 300px;
  overflow-y: auto;
}

.gs-sequence-display h4 {
  color: #6d28d9;
  margin: 0 0 10px 0;
  font-weight: 800;
  font-size: 16px;
}

.gs-term {
  display: inline-block;
  padding: 8px 12px;
  margin: 5px;
  background-color: #f3e8ff;
  border-radius: 6px;
  font-weight: 600;
  color: #5b21b6;
}

.gs-convergence-alert {
  padding: 15px;
  border-radius: 8px;
  margin-top: 15px;
  font-weight: 700;
}

.gs-convergent {
  background-color: #d1fae5;
  border-left: 5px solid #10b981;
  color: #065f46;
}

.gs-divergent {
  background-color: #fee2e2;
  border-left: 5px solid #ef4444;
  color: #991b1b;
}

.formula-box {
  background-color: #fef3c7;
  border: 2px solid #f59e0b;
  border-radius: 8px;
  padding: 20px;
  margin: 20px 0;
  font-weight: 600;
}

.formula-box h4 {
  color: #d97706;
  margin-bottom: 12px;
  font-weight: 800;
  font-size: 18px;
}

.example-box {
  background-color: #eff6ff;
  border: 2px solid #3b82f6;
  border-radius: 8px;
  padding: 20px;
  margin: 20px 0;
}

.example-box h4 {
  color: #1e40af;
  margin-bottom: 12px;
  font-weight: 800;
  font-size: 18px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  background-color: #ffffff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

table th {
  background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
  color: #ffffff;
  padding: 14px;
  text-align: left;
  font-weight: 800;
  font-size: 15px;
}

table td {
  padding: 12px 14px;
  border-bottom: 1px solid #ecf0f1;
  font-weight: 600;
  color: #2c3e50;
}

table tr:hover {
  background-color: #faf5ff;
}

ul, ol {
  margin: 15px 0;
  padding-left: 25px;
}

ul li, ol li {
  margin-bottom: 10px;
  font-weight: 600;
  color: #444;
  line-height: 1.6;
}

.highlight-box {
  background-color: #fef9c3;
  border-left: 5px solid #eab308;
  padding: 18px;
  margin: 20px 0;
  border-radius: 6px;
}

.highlight-box strong {
  color: #854d0e;
  font-weight: 800;
}

.info-box {
  background-color: #faf5ff;
  border-left: 5px solid #8b5cf6;
  padding: 18px;
  margin: 20px 0;
  border-radius: 6px;
}

.info-box strong {
  color: #6d28d9;
  font-weight: 800;
}

@media (max-width: 768px) {
  #geometric-series-calculator-section h1 {
    font-size: 26px;
  }
  
  #geometric-series-calculator-section h2 {
    font-size: 21px;
  }
  
  #geometric-series-calculator-section h3 {
    font-size: 18px;
  }
  
  .gs-calculator-container {
    padding: 20px;
  }
  
  .gs-two-column {
    grid-template-columns: 1fr;
  }
  
  .gs-mode-btn {
    padding: 10px 15px;
    font-size: 14px;
  }
  
  .gs-calc-button {
    font-size: 16px;
    padding: 14px;
  }
  
  table {
    font-size: 14px;
  }
  
  table th, table td {
    padding: 10px 8px;
  }
}

@media (max-width: 480px) {
  #geometric-series-calculator-section {
    padding: 15px;
  }
  
  #geometric-series-calculator-section h1 {
    font-size: 22px;
  }
  
  .gs-mode-btn {
    width: 100%;
  }
}

}
