* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", sans-serif;
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  min-height: 100vh;
  color: #e4e4e7;
  padding: 20px;
  overflow-x: hidden;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
}

/* Header Styles */
.header {
  text-align: center;
  margin-bottom: 50px;
  padding: 40px 20px;
}

.header-title {
  font-size: 48px;
  font-weight: 700;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
  letter-spacing: -1px;
}

.header-subtitle {
  font-size: 18px;
  color: #a1a1aa;
  font-weight: 400;
}

/* Search Wrapper */
.search-wrapper {
  max-width: 600px;
  margin: 0 auto 60px;
}

.search-box {
  position: relative;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 20px;
  color: #71717a;
  pointer-events: none;
  z-index: 1;
}

.search {
  width: 100%;
  padding: 18px 20px 18px 52px;
  font-size: 16px;
  border-radius: 16px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  outline: none;
  color: #fff;
  transition: all 0.3s ease;
  font-weight: 400;
  letter-spacing: 0.3px;
}

.search::placeholder {
  color: #71717a;
}

.search:focus {
  border-color: rgba(102, 126, 234, 0.5);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 32px rgba(102, 126, 234, 0.2);
  transform: translateY(-2px);
}

/* Cards Carousel Container */
.cards {
  position: relative;
  overflow: hidden;
  padding: 20px 0;
  margin: 0 -20px;
}

.cards-track {
  display: flex;
  gap: 20px;
  animation: slideLeft 30s linear infinite;
  width: max-content;
}

/* Pause animation on hover */
.cards:hover .cards-track {
  animation-play-state: paused;
}

/* Sliding Animation */
@keyframes slideLeft {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Individual Card - Smaller Size */
.card {
  position: relative;
  width: 220px;
  height: 280px;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  border: 2px solid rgba(255, 255, 255, 0.05);
  flex-shrink: 0;
}

.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 1;
}

.card:hover::before {
  opacity: 1;
}

.card:hover {
  transform: translateY(-8px) scale(1.05);
  box-shadow:
    0 20px 40px rgba(102, 126, 234, 0.3),
    0 0 0 2px rgba(102, 126, 234, 0.4);
  border-color: rgba(102, 126, 234, 0.5);
}

.card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.card:hover img {
  transform: scale(1.08);
}

/* Blur Overlay */
.blur-layer {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 0%, rgba(0, 0, 0, 0.3) 40%, rgba(0, 0, 0, 0.85) 100%);
  z-index: 1;
}

/* Content */
.content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  color: #fff;
  z-index: 2;
  transform: translateY(0);
  transition: transform 0.3s ease;
}

.card:hover .content {
  transform: translateY(-5px);
}

.content h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 6px;
  letter-spacing: -0.5px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.content p {
  font-size: 13px;
  opacity: 0.95;
  font-weight: 400;
  line-height: 1.4;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
  color: #e4e4e7;
}

.card.hidden {
  display: none;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .header-title {
    font-size: 40px;
  }

  .card {
    width: 200px;
    height: 260px;
  }
}

@media (max-width: 768px) {
  body {
    padding: 15px;
  }

  .header {
    margin-bottom: 35px;
    padding: 30px 15px;
  }

  .header-title {
    font-size: 36px;
  }

  .header-subtitle {
    font-size: 16px;
  }

  .search-wrapper {
    margin-bottom: 40px;
  }

  .card {
    width: 180px;
    height: 240px;
  }

  .content h3 {
    font-size: 16px;
  }

  .content p {
    font-size: 12px;
  }

  .cards-track {
    gap: 15px;
  }
}

@media (max-width: 480px) {
  .header-title {
    font-size: 32px;
  }

  .card {
    width: 160px;
    height: 220px;
  }

  .content {
    padding: 15px;
  }

  .content h3 {
    font-size: 15px;
  }

  .content p {
    font-size: 11px;
  }
}

/* Smooth Entry Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.card {
  animation: fadeIn 0.5s ease-out backwards;
}
