.demo-container {
  container-type: inline-size;
  border: 2px dashed #6c757d;
  padding: 16px;
  margin: 16px 0;
  resize: horizontal;
  overflow: hidden;
  min-width: 200px;
  max-width: 100%;
  background: #f8f9fa;
}

.responsive-card {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  overflow: hidden;
  transition: all 0.3s ease;
}

.card-image {
  width: 100%;
  height: 120px;
  background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
}

.card-content {
  padding: 16px;
}

.card-title {
  margin: 0 0 8px 0;
  font-size: 1.2em;
  font-weight: bold;
  color: #333;
}

.card-text {
  margin: 0;
  color: #666;
  line-height: 1.4;
}

/* Container queries for the card */
@container (min-width: 400px) {
  .responsive-card {
    display: flex;
    align-items: stretch;
  }
  
  .card-image {
    width: 160px;
    height: auto;
    flex-shrink: 0;
  }
  
  .card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
}

@container (min-width: 600px) {
  .card-title {
    font-size: 1.5em;
  }
  
  .card-text {
    font-size: 1.1em;
  }
  
  .card-image {
    width: 200px;
  }
}

.resize-hint {
  font-size: 12px;
  color: #6c757d;
  margin-bottom: 8px;
  font-style: italic;
}