/* Reset and basic styles */

body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  background-color: #f9f9f9;
  margin: 0; /* Reset default margin */
  display: flex;
  flex-direction: column;
  min-height: 100vh; /* Ensure full viewport height */
}

main {
  flex: 1; /* Expand main content to fill remaining vertical space */
  padding: 20px;
}

header {
  display: flex;
  align-items: center;
  background: #000;
  padding: 10px 20px;
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  height: 60px; /* Set a specific height */
}

.logo img {
  height: 40px;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 20px;
  margin-left: auto; /* Push nav items to the right */
}

nav a {
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  position: relative;
  transition: color 0.3s;
}

nav a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  display: block;
  margin-top: 5px;
  right: 0;
  background: #fff;
  transition: width 0.3s ease, background-color 0.3s ease;
}

nav a:hover::after {
  width: 100%;
  left: 0;
  background: #fff;
}

nav a:hover {
  color: #ffcc00; /* Change to desired hover color */
}

.car-details {
  display: flex;
  justify-content: center;
  align-items: flex-start; /* Adjust alignment to start from the top */
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 80px; /* Ensure space below fixed header */
  padding: 20px; /* Added padding for spacing */
}

.car-image img {
  width: 100%; /* Ensure the image takes full width of its container */
  max-width: 100%; /* Ensure the image doesn't exceed its natural size */
  max-height: 400px; /* Set maximum height for the image */
  object-fit: cover; /* Maintain aspect ratio and cover container */
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.car-info {
  max-width: 500px;
}

.car-info h1 {
  font-size: 2.5rem;
  margin-bottom: 10px;
}

.car-info p {
  font-size: 1.1rem;
  margin-bottom: 15px;
  color: #333;
}

footer {
  background: #000;
  color: #fff;
  text-align: center;
  padding: 10px 0;
  position: relative;
  width: 100%;
}

/* Animation for text */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.car-info h1,
.car-info p {
  animation: fadeInUp 0.6s ease forwards;
}

@media (max-width: 768px) {
  .car-details {
    margin-top: 140px; /* Adjust for smaller screens */
  }
}
