/* Cards Container */
#cards-section {
  margin: 120px 0;
  padding: 60px 0;
}

#cards-section h2 {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 48px;
  letter-spacing: -0.01em;
}

.cards-container {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-height: 600px;
  overflow: visible;
  padding: 40px 0;
  --card-width: 300px;
  --card-height: 400px;
}

@media (max-width: 1024px) {
  .cards-container {
    --card-width: 220px;
    --card-height: 300px;
    min-height: 500px;
  }
}

@media (max-width: 640px) {
  .cards-container {
    --card-width: 200px;
    --card-height: 280px;
    padding: 20px 0;
    min-height: 450px;
  }

  #cards-section h2 {
    font-size: 24px;
    margin-bottom: 32px;
  }
}

/* Card Base Styles */
.card {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-weight: 600;
  color: white;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  outline: none;
  will-change: transform;
}

.card:hover:not(.active) {
  filter: brightness(1.05);
}

.card:active {
  filter: brightness(0.98);
}

/* Card Colors */
.card-orange {
  background: linear-gradient(135deg, #ea580c 0%, #ff6b35 100%);
  color: white;
}

.card-stone {
  background: linear-gradient(135deg, #e7e5e4 0%, #f5f5f4 100%);
  color: #1f2937;
}

.card-stone .card-description {
  color: rgba(31, 41, 55, 0.8);
}

.card-blue {
  background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
  color: white;
}

.card-purple {
  background: linear-gradient(135deg, #7c3aed 0%, #a855f7 100%);
  color: white;
}

.card-dark {
  background: linear-gradient(135deg, #1f2937 0%, #374151 100%);
  color: white;
}

/* Card Skeleton */
.card-skeleton {
  width: 100%;
  height: 120px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.15);
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0%, 100% {
    opacity: 0.8;
  }
  50% {
    opacity: 1;
  }
}

@keyframes bounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-3px);
  }
}

/* Card Content */
.card-title {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: inherit;
}

.card-description {
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 400;
}

/* Responsive Title Size */
@media (max-width: 1024px) {
  .card-title {
    font-size: 16px;
  }

  .card-description {
    font-size: 12px;
  }
}

@media (max-width: 640px) {
  .card-title {
    font-size: 14px;
  }

  .card-description {
    font-size: 11px;
  }
}

/* Media Cards (variant): white frame, rounded media, caption below */
.card-photo {
  padding: 12px !important;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.12);
  color: #111;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  overflow: hidden;
}

.card-photo .card-media {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  border-radius: 12px;
  overflow: hidden;
  background: #ececec;
}

.card-photo .card-media-el {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.card-photo:hover .card-media-el {
  transform: scale(1.05);
}

/* Crossfade for auto-cycling image sets */
.card-photo .card-slide {
  opacity: 0;
  transition: opacity 0.8s ease, transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.card-photo .card-slide.is-active {
  opacity: 1;
}

.card-photo .card-mute {
  position: absolute;
  bottom: 10px;
  right: 10px;
  z-index: 3;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  transition: background 0.2s ease;
}

.card-photo .card-mute:hover {
  background: rgba(0, 0, 0, 0.72);
}

.card-photo .card-mute svg {
  display: block;
}

.card-photo .card-info {
  flex: 0 0 auto;
  padding: 14px 4px 4px;
  text-align: left;
}

.card-photo .card-tag {
  display: block;
  font-family: var(--font-mono);
  font-size: var(--text-eyebrow);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #16a34a;
  margin-bottom: 10px;
}

.card-photo .card-title {
  color: #111;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0;
}

.card-photo .card-description {
  color: #8a8a8a;
  font-size: 14px;
  line-height: 1.45;
  font-weight: 400;
  margin: 8px 0 0 0;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition: opacity 0.5s ease, max-height 0.5s ease;
}
