.demo-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.demo-section {
  margin-bottom: 3rem;
  
  h2 {
    font-size: 1.875rem;
    color: #1f2937;
    margin-bottom: 1.5rem;
  }
  
  h3 {
    font-size: 1.5rem;
    color: #1f2937;
    margin-bottom: 1rem;
    border-bottom: 1px solid #d1d5db;
    padding-bottom: 0.75rem;
  }
  
  h4 {
    font-size: 1.25rem;
    color: #1f2937;
    margin-bottom: 0.5rem;
  }
  
  h5 {
    font-size: 1.125rem;
    color: #1f2937;
    margin-bottom: 0.25rem;
  }
}

.demo-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: flex-start;
}

.demo-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.375rem;
  background: #ffffff;
  min-width: 120px;
  
  p {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
    text-align: center;
    text-transform: capitalize;
  }
}

.demo-interactive {
  padding: 1rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  background: #f9fafb;
  
  .demo-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e5e7eb;
    
    label {
      display: flex;
      flex-direction: column;
      gap: 0.25rem;
      font-size: 0.875rem;
      color: #1f2937;
      font-weight: 500;
      
      select {
        padding: 0.25rem 0.5rem;
        border: 1px solid #d1d5db;
        border-radius: 0.25rem;
        background: #ffffff;
        color: #1f2937;
        font-size: 0.875rem;
        
        &:focus {
          outline: 2px solid #3b82f6;
          outline-offset: 2px;
          border-color: #3b82f6;
        }
      }
      
      input[type="checkbox"] {
        margin-right: 0.25rem;
      }
    }
  }
  
  .demo-result {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 120px;
    background: #ffffff;
    border: 1px dashed #d1d5db;
    border-radius: 0.375rem;
  }
  
  p {
    text-align: center;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: #6b7280;
  }
}

.demo-usage {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1rem;
}

.usage-example {
  padding: 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  background: #ffffff;
  
  .demo-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: #6366f1;
    color: #ffffff;
    border: none;
    border-radius: 0.375rem;
    font-size: 1rem;
    cursor: pointer;
    transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);
    
    &:hover:not(:disabled) {
      background: #5855eb;
      box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    }
    
    &:disabled {
      opacity: 0.6;
      cursor: not-allowed;
    }
    
    &:focus-visible {
      outline: 2px solid #3b82f6;
      outline-offset: 2px;
    }
  }
  
  .page-loading-example,
  .processing-example {
    min-height: 150px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.25rem;
    background: #f9fafb;
    
    .page-content,
    .process-result {
      text-align: center;
      
      p {
        margin: 0.5rem 0;
        color: #6b7280;
      }
      
      button {
        padding: 0.25rem 0.5rem;
        background: #64748b;
        color: #ffffff;
        border: none;
        border-radius: 0.25rem;
        font-size: 0.875rem;
        cursor: pointer;
        transition: background 150ms cubic-bezier(0.4, 0, 0.2, 1);
        
        &:hover {
          background: #475569;
        }
        
        &:focus-visible {
          outline: 2px solid #3b82f6;
          outline-offset: 2px;
        }
      }
    }
  }
}

// Responsive breakpoints
@media (max-width: 768px) {
  .demo-container {
    padding: 1rem;
  }
  
  .demo-row {
    gap: 0.75rem;
  }
  
  .demo-item {
    min-width: 100px;
    padding: 0.5rem;
  }
  
  .demo-interactive .demo-controls {
    flex-direction: column;
    align-items: flex-start;
    
    label {
      width: 100%;
      
      select {
        width: 100%;
      }
    }
  }
  
  .demo-usage {
    grid-template-columns: 1fr;
  }
}