/* Car Grid Styles */
.car-grid-section {
  padding: 5rem 2rem;
  position: relative;
  background: linear-gradient(180deg, #0a0a0a 0%, #1a1a1a 100%);
  overflow: hidden;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
  position: relative;
  z-index: 2;
}

.section-title {
  font-family: "Playfair Display", serif;
  font-size: 3.5rem;
  color: #fff;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 3px;
  background: linear-gradient(90deg, #ffd700, #b8860b);
  border-radius: 3px;
}

.section-subtitle {
  color: #aaa;
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.6;
}

.car-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2rem;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 2rem;
  position: relative;
  z-index: 2;
}

.car-card {
  background: rgba(20, 20, 20, 0.8);
  border-radius: 15px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  position: relative;
  border: 1px solid rgba(255, 215, 0, 0.1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  transform: translateY(0);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.car-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  border-color: rgba(255, 215, 0, 0.3);
}

.car-image-container {
  position: relative;
  overflow: hidden;
  height: 220px;
  padding: 0 25px;
}

.car-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.7s ease;
}

.car-card:hover .car-image {
  transform: scale(1.05);
}

.car-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: linear-gradient(135deg, #ffd700, #b8860b);
  color: #000;
  padding: 0.2rem 0.8rem;
  border-radius: 20px;
  font-size: 0.6rem;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1px;
  z-index: 2;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.car-details {
  padding: 1.8rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
  background: linear-gradient(
    180deg,
    rgba(30, 30, 30, 0.9) 0%,
    rgba(20, 20, 20, 0.98) 100%
  );
}

.car-name {
  font-family: "Playfair Display", serif;
  font-size: 1.8rem;
  margin: 0 0 0.5rem;
  color: #fff;
  position: relative;
  display: inline-block;
}

.car-specs {
  display: flex;
  gap: 1.5rem;
  margin: 0.8rem 0 1.5rem;
  color: #aaa;
  font-size: 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 1.2rem;
}

.spec {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.spec i {
  color: #ffd700;
  font-size: 1rem;
}

.car-price {
  font-size: 1.8rem;
  font-weight: bold;
  color: #ffd700;
  margin: 0.5rem 0 1.5rem;
  font-family: "Inria Sans", sans-serif;
}

.car-description {
  color: #bbb;
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.8rem;
  flex-grow: 1;
}

.car-link {
  display: inline-block;
  background: linear-gradient(135deg, #ffd700, #b8860b);
  color: #000;
  padding: 0.8rem 1.8rem;
  border-radius: 30px;
  text-decoration: none;
  font-weight: bold;
  text-align: center;
  transition: all 0.3s ease;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 1px;
  margin-top: auto;
  align-self: flex-start;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.car-link::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: 0.5s;
  z-index: -1;
}

.car-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(255, 215, 0, 0.3);
}

.car-link:hover::before {
  left: 100%;
}

/* Individual Car Card Styles */
.car-card:nth-child(3n + 1) {
  border-top: 3px solid #ffd700;
}

.car-card:nth-child(3n + 2) {
  border-top: 3px solid #b8860b;
}

.car-card:nth-child(3n + 3) {
  border-top: 3px solid #ffa500;
}

/* Hover Effects */
.car-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    45deg,
    transparent,
    rgba(255, 215, 0, 0.05),
    transparent
  );
  z-index: 0;
  opacity: 0;
  transition: opacity 0.4s ease;
}

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

/* Responsive Design */
@media (max-width: 1200px) {
  .car-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  }
}

@media (max-width: 768px) {
  .car-grid-section {
    padding: 3rem 1rem;
  }

  .section-title {
    font-size: 2.5rem;
  }

  .section-subtitle {
    font-size: 1rem;
  }

  .car-grid {
    grid-template-columns: 1fr;
    padding: 0 1rem;
  }

  .car-card {
    max-width: 100%;
  }
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.car-card {
  animation: fadeInUp 0.6s ease-out forwards;
  opacity: 0;
}

.car-card:nth-child(1) {
  animation-delay: 0.1s;
}
.car-card:nth-child(2) {
  animation-delay: 0.2s;
}
.car-card:nth-child(3) {
  animation-delay: 0.3s;
}
.car-card:nth-child(4) {
  animation-delay: 0.4s;
}
.car-card:nth-child(5) {
  animation-delay: 0.5s;
}
.car-card:nth-child(6) {
  animation-delay: 0.6s;
}
.car-card:nth-child(7) {
  animation-delay: 0.7s;
}
.car-card:nth-child(8) {
  animation-delay: 0.8s;
}
.car-card:nth-child(9) {
  animation-delay: 0.9s;
}
