/* ============================================
   LLM Context Window Comparison Styles
   ============================================ */

/* Breadcrumb Navigation */
.breadcrumb-nav {
  background: #fff;
  border-bottom: 1px solid #e9ecef;
  padding: 0.75rem 1rem;
}

.breadcrumb-nav .container {
  max-width: 1200px;
  margin: 0 auto;
}

.breadcrumb-list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.875rem;
}

.breadcrumb-list li a {
  color: #6c757d;
  text-decoration: none;
  transition: color 0.2s ease;
}

.breadcrumb-list li a:hover {
  color: #212529;
}

.breadcrumb-list li[aria-current="page"] {
  color: #212529;
  font-weight: 500;
}

.breadcrumb-separator {
  color: #6c757d;
  font-size: 0.75rem;
}

/* Tool Header */
.tool-header {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  padding: 3rem 1rem 2rem;
  text-align: center;
}

.tool-header .container {
  max-width: 900px;
  margin: 0 auto;
}

.tool-title {
  font-size: clamp(1.75rem, 5vw, 3rem);
  font-weight: 700;
  color: #212529;
  margin-bottom: 1.5rem;
  letter-spacing: -0.5px;
}

.tool-description {
  font-size: clamp(0.95rem, 2.5vw, 1.15rem);
  color: #6c757d;
  max-width: 800px;
  margin: 0 auto 2rem;
  line-height: 1.6;
}

.quick-stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}

.stat-item {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  color: #212529;
  margin-bottom: 0.25rem;
}

.stat-label {
  display: block;
  font-size: 0.875rem;
  color: #6c757d;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Calculator Section */
.calculator-section {
  background: #fff;
  padding: 3rem 1rem;
}

.calculator-container {
  max-width: 900px;
  margin: 0 auto;
}

.section-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  color: #212529;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.section-title i {
  color: #6c757d;
  font-size: 0.9em;
}

.section-subtitle {
  color: #6c757d;
  font-size: 1rem;
  margin-bottom: 2rem;
}

.calculator-card {
  background: #ffffff;
  border: 2px solid #e9ecef;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.calculator-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 2rem;
  border-bottom: 2px solid #e9ecef;
}

.calc-tab {
  background: transparent;
  border: none;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: #6c757d;
  cursor: pointer;
  transition: all 0.2s ease;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
}

.calc-tab:hover {
  color: #212529;
}

.calc-tab.active {
  color: #212529;
  border-bottom-color: #212529;
}

.calc-tab i {
  margin-right: 0.5rem;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.input-group label {
  font-weight: 600;
  color: #212529;
  font-size: 0.95rem;
}

.calc-input, .calc-select {
  padding: 0.75rem 1rem;
  font-size: 1rem;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  transition: all 0.2s ease;
  font-family: inherit;
}

.calc-input:focus, .calc-select:focus {
  outline: none;
  border-color: #212529;
  box-shadow: 0 0 0 3px rgba(33, 37, 41, 0.1);
}

.calc-select {
  cursor: pointer;
  background-color: #fff;
}

.calculator-result {
  margin-top: 2rem;
  padding: 1.5rem;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #212529;
}

.result-tokens {
  font-size: 1.25rem;
  margin-bottom: 1rem;
  color: #212529;
}

.result-tokens strong {
  font-weight: 700;
}

.result-tokens span {
  color: #0066cc;
  font-weight: 700;
}

.result-message {
  color: #6c757d;
  line-height: 1.6;
}

.result-message .compat-good {
  color: #155724;
  font-weight: 600;
}

.result-message .compat-limited {
  color: #856404;
  font-weight: 600;
}

.result-message .compat-tight {
  color: #dc6900;
  font-weight: 600;
}

.result-message .compat-bad {
  color: #721c24;
  font-weight: 600;
}

/* Context Info Box */
.context-info-box {
  margin-top: 2rem;
  background: #fff3cd;
  border: 2px solid #ffc107;
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  gap: 1rem;
}

.info-icon {
  flex-shrink: 0;
  font-size: 2rem;
  color: #ff9800;
}

.info-content h3 {
  font-size: 1.125rem;
  font-weight: 700;
  color: #212529;
  margin-bottom: 0.75rem;
}

.info-content p {
  color: #495057;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.info-examples {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1rem;
}

.info-example {
  background: rgba(255, 255, 255, 0.7);
  padding: 1rem;
  border-radius: 8px;
}

.info-example.reasoning-note {
  background: #e7f3ff;
  border-left: 4px solid #0066cc;
}

.example-label {
  display: block;
  font-weight: 600;
  color: #212529;
  margin-bottom: 0.5rem;
}

.info-example ul {
  margin: 0.5rem 0 0 1.5rem;
  color: #495057;
}

.info-example ul li {
  margin-bottom: 0.25rem;
}

/* Comparison Section */
.comparison-section {
  background: #f8f9fa;
  padding: 3rem 1rem;
}

.comparison-container {
  max-width: 1400px;
  margin: 0 auto;
}

/* Filters */
.filters-section {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
  align-items: center;
}

.search-box {
  flex: 0 1 300px;
  min-width: 200px;
  max-width: 300px;
  position: relative;
}

.search-box i {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: #6c757d;
}

.context-search-input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  font-size: 1rem;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.context-search-input:focus {
  outline: none;
  border-color: #212529;
  box-shadow: 0 0 0 3px rgba(33, 37, 41, 0.1);
}

.filter-controls {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.filter-select {
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 180px;
}

.filter-select:focus {
  outline: none;
  border-color: #212529;
}

.btn-clear-filters {
  padding: 0.75rem 1.25rem;
  font-size: 0.95rem;
  font-weight: 600;
  background: #fff;
  color: #6c757d;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-clear-filters:hover {
  background: #f8f9fa;
  border-color: #6c757d;
  color: #212529;
}

/* Comparison Table */
.table-wrapper {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.comparison-table thead {
  background: #212529;
  color: #fff;
}

.comparison-table th {
  padding: 1rem;
  text-align: left;
  font-weight: 600;
  white-space: nowrap;
}

.comparison-table th.sortable {
  cursor: pointer;
  user-select: none;
  transition: background 0.2s ease;
}

.comparison-table th.sortable:hover {
  background: #343a40;
}

.comparison-table th.sortable i {
  margin-left: 0.25rem;
  font-size: 0.875rem;
  opacity: 0.7;
}

.comparison-table th.sortable.active i {
  opacity: 1;
}

.comparison-table tbody tr {
  border-bottom: 1px solid #e9ecef;
  transition: background 0.2s ease;
}

.comparison-table tbody tr:hover {
  background: #f8f9fa;
}

.comparison-table tbody tr.hidden {
  display: none;
}

.comparison-table tbody tr.filtered-out {
  display: none;
}

.comparison-table td {
  padding: 1rem;
}

.model-name {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.model-name strong {
  color: #212529;
  font-weight: 600;
}

.model-id {
  color: #6c757d;
  font-size: 0.875rem;
  font-family: 'Courier New', monospace;
}

.provider-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: #e9ecef;
  color: #495057;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 500;
}

.context-window {
  font-size: 1rem;
}

.context-window strong {
  color: #212529;
  font-weight: 700;
}

.context-window small {
  display: block;
  color: #6c757d;
  font-size: 0.75rem;
}

.price-cell {
  color: #212529;
  font-weight: 600;
}

.price-cell small {
  display: block;
  color: #6c757d;
  font-size: 0.75rem;
  font-weight: 400;
}

.value-score {
  font-weight: 700;
  color: #0066cc;
  font-size: 1.05rem;
}

/* .compatibility-cell {
  text-align: center;
} */

.compat-indicator {
  display: inline-block;
  padding: 0.35rem 0.75rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 600;
}

.compat-indicator.excellent {
  background: #d4edda;
  color: #155724;
}

.compat-indicator.good {
  background: #fff3cd;
  color: #856404;
}

.compat-indicator.limited {
  background: #f8d7da;
  color: #721c24;
}

.compat-indicator.incompatible {
  background: #e9ecef;
  color: #6c757d;
}

.actions-cell {
  text-align: center;
}

.btn-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: #212529;
  color: #fff;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-action:hover {
  background: #343a40;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.empty-state {
  text-align: center;
  padding: 3rem 1rem;
  color: #6c757d;
}

.empty-state i {
  font-size: 3rem;
  margin-bottom: 1rem;
  opacity: 0.5;
}

.value-score-note {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  background: #fff;
  border-radius: 8px;
  font-size: 0.875rem;
  color: #6c757d;
}

/* Load More Button */
.load-more-container {
  display: flex;
  justify-content: center;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.btn-load-more {
  padding: 0.8rem 2rem;
  background-color: #fff;
  color: #212529;
  border: 2px solid #212529;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.btn-load-more:hover {
  background-color: #212529;
  color: #fff;
}

.btn-load-more i {
  font-size: 0.8rem;
}

/* Use Cases Section */
.use-cases-section {
  background: #fff;
  padding: 3rem 1rem;
}

.use-cases-section .container {
  max-width: 1200px;
  margin: 0 auto;
}

.use-cases-section h2 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  color: #212529;
  text-align: center;
  margin-bottom: 2rem;
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.use-case-card {
  background: #f8f9fa;
  border: 2px solid #e9ecef;
  border-radius: 12px;
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.use-case-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
  border-color: #212529;
}

.use-case-icon {
  width: 48px;
  height: 48px;
  background: #212529;
  color: #fff;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.use-case-card h3 {
  font-size: 1.125rem;
  font-weight: 700;
  color: #212529;
  margin-bottom: 1rem;
}

.use-case-content p {
  margin-bottom: 0.5rem;
  color: #495057;
  line-height: 1.6;
}

.use-case-content p strong {
  color: #212529;
}

/* Examples Section */
.examples-section {
  background: #f8f9fa;
  padding: 3rem 1rem;
}

.examples-section .container {
  max-width: 1200px;
  margin: 0 auto;
}

.examples-section h2 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  color: #212529;
  text-align: center;
  margin-bottom: 0.5rem;
}

.examples-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.example-card {
  background: #fff;
  border: 2px solid #e9ecef;
  border-radius: 12px;
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s ease;
}

.example-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
  border-color: #212529;
}

.example-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 8px;
  background: #ffffff;
  color: #212529;
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
  border: 1px solid #e9ecef;
}

.example-icon i {
  color: #212529;
  font-size: 1.25rem;
}

.example-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1rem;
}

.example-content h3 {
  font-size: 1.125rem;
  font-weight: 700;
  color: #212529;
  margin-bottom: 0.5rem;
}

.example-tokens {
  font-size: 1.25rem;
  font-weight: 700;
  color: #0066cc;
  margin-bottom: 0.5rem;
}

.example-desc {
  color: #6c757d;
  font-size: 0.875rem;
}

/* Related Tools Section */
.related-tools-section {
  background: #fff;
  padding: 3rem 1rem;
  border-top: 1px solid #e9ecef;
}

.related-tools-section .container {
  max-width: 900px;
  margin: 0 auto;
}

.related-tools-section h2 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  color: #212529;
  text-align: center;
  margin-bottom: 2rem;
}

.related-tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.related-tool-card {
  background: #f8f9fa;
  border: 2px solid #e9ecef;
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  text-decoration: none;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.related-tool-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
  border-color: #212529;
}

.tool-icon-large {
  width: 64px;
  height: 64px;
  background: #212529;
  color: #fff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin-bottom: 1.5rem;
}

.related-tool-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #212529;
  margin-bottom: 0.75rem;
}

.related-tool-card p {
  color: #6c757d;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.tool-link {
  color: #0066cc;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.related-tool-card:hover .tool-link {
  gap: 0.75rem;
}

/* Responsive Design */
@media (max-width: 768px) {
  .quick-stats {
    gap: 2rem;
  }
  
  .stat-number {
    font-size: 1.5rem;
  }
  
  .calculator-card {
    padding: 1.5rem;
  }
  
  .calc-tab {
    padding: 0.65rem 1rem;
    font-size: 0.9rem;
  }
  
  .form-row {
    grid-template-columns: 1fr;
  }
  
  .context-info-box {
    flex-direction: column;
  }
  
  .filters-section {
    flex-direction: column;
  }
  
  .search-box {
    width: 100%;
    max-width: none;
    flex: 1 1 100%;
  }
  
  .filter-controls {
    width: 100%;
    flex-direction: column;
  }
  
  .filter-select {
    width: 100%;
  }
  
  .table-wrapper {
    overflow-x: auto;
  }
  
  .comparison-table {
    font-size: 0.875rem;
  }
  
  .comparison-table th,
  .comparison-table td {
    padding: 0.75rem 0.5rem;
  }
  
  .use-cases-grid {
    grid-template-columns: 1fr;
  }
  
  .examples-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
  
  .related-tools-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .breadcrumb-list {
    font-size: 0.8125rem;
  }
  
  .tool-header {
    padding: 2rem 1rem 1.5rem;
  }
  
  .section-title {
    font-size: 1.25rem;
  }
  
  .calculator-tabs {
    gap: 0.25rem;
  }
  
  .calc-tab {
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
  }
  
  .comparison-table {
    font-size: 0.8125rem;
  }
  
  .provider-badge {
    font-size: 0.8125rem;
    padding: 0.2rem 0.6rem;
  }
}
