/* General Styles */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-image: url('./Photos/CarBackground2.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    overflow-x: hidden; /* Prevent horizontal scrolling */
}

/* Dark overlay using body::before */
body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(207, 207, 190, 0.5); /* Dark overlay */
    z-index: -1; /* Makes sure the overlay is behind content */
    height: 100vh;
}

header {
    background-color: rgba(0, 0, 0, 0.6); /* Semi-transparent background to make text more readable */
    color: rgb(218, 202, 65);
    padding: 40px 20px;
    text-align: center;
    position: sticky;
    top: 0;
    z-index: 1000;

}

h1 {
    font-size: 3rem; /* Increase the font size */
    font-family: 'Roboto', sans-serif; /* Apply the custom font */
    font-weight: bold;
    margin: 0;
}

nav ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

nav ul li {
    display: inline;
    margin-right: 15px;
}

nav ul li a {
    color: rgb(163, 140, 140);
    text-decoration: none;
    font-size: 16px;
}

.logo img {
    width: 300px; /* Adjust the width of the logo */
    height: 200px; /* Maintain aspect ratio */
    display: block; /* Center the image if parent is flex/inline-block */
    margin: 0 auto; /* Center the logo within its container */
}

.social-icons {
    margin-top: 10px;
}

.social-icons .social-icon {
    margin: 0 10px;
}

.social-icons img {
    width: 30px;
    transition: transform 0.3s ease;
}

.social-icons .social-icon:hover img {
    transform: scale(1.2);
}

/* Main Content */
main {
    padding: 20px;
    animation: fadeIn 1s ease-out;
}

h2 {
    text-align: center;
    color: #fff;
}

/* Main Home Section */
#home {
    display: flex;
    justify-content: center;  /* Centers content horizontally */
    align-items: center;      /* Centers content vertically */
    height: 110vh;             /* Make sure it covers full viewport height */
    width: 97%;              /* Adjust to fit the desired section width */
    text-align: center;        /* Centers text inside */
    color: white;              /* Text color */
    background-color: rgba(0, 0, 0, 0.6); /* Optional: Darken the background for readability */
    background-size: cover;   /* Ensure the background image covers the section */
    background-position: center; /* Center the image */
    background-attachment: fixed; /* Optional: Keeps the image fixed while scrolling */
    transition: opacity 0.5s ease; /* Smooth opacity transition */
    overflow: hidden;
    position: relative;
    padding: 20px; /* Optional: Add some padding */
}

/* Centered Slideshow */
.slideshow-container {
    position: relative;
    width: 95%; /* Confines slideshow width */
    height: 85%; /* Confines slideshow height */
    margin: 0 auto;
    overflow: hidden;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px; /* Optional: Rounded edges */
    background: rgba(0, 0, 0, 0.4); /* Semi-transparent black background */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5); /* Optional: Adds depth */
    top: 5%;
}

/* Slideshow: Confined to #home */
.slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    overflow: hidden;
}

.slides {
    display: none; /* Start with all slides hidden */
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slides img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px; /* Optional: Rounded edges for images */
}

/* Fade Effect */
.fade {
    animation: fadeEffect 12s infinite; /* Slower animation: 12 seconds */
}

@keyframes fadeEffect {
    0% {
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        opacity: 0;
    }
}

.slides {
    animation: fadeEffect 10s infinite; /* 20 seconds for the full slideshow cycle */
}

/* Individual Slides with Delay */
.slides:nth-child(1) {
    animation-delay: 5s;
}

.slides:nth-child(2) {
    animation-delay: 5s; /* Delays this slide by 5 seconds */
}

.slides:nth-child(3) {
    animation-delay: 10s; /* Delays this slide by 10 seconds */
}

.slides:nth-child(4) {
    animation-delay: 15s; /* Delays this slide by 15 seconds */
}

/* Show First Slide by Default */
.slides:first-child {
    display: block;
}

/* Overlay Text */
.overlay-text {
    position: absolute;
    top: .001%;
    text-align: center;
    z-index: 2;
    width:85%;
    color: white;
    text-shadow: 0px 4px 6px rgba(211, 211, 199, 0.8);
    animation: fadeInUp 1.5s ease-in-out;
    background: transparent;
}

.overlay-text p {
    font-size: 32px;
    line-height: 1.5;
    font-family: 'Verdana', sans-serif;
    background: rgba(110, 108, 108, 0.6);
    padding: 10px 20px;
    border-radius: 10px;
    display: inline-block;
}

/* Optional: Style for the heading inside Home */
#home h2 {
    font-family: 'Georgia', serif; /* Custom font style for <h2> */
    font-size: 55px; /* Larger font size for <h2> */
    color: #dbe1e7;
    margin-Top: 15px; /* Space below the heading */
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px); /* Starts 20px lower */
    }
    to {
        opacity: 1;
        transform: translateY(0); /* Ends in the original position */
    }
}

/* Optional: Style for the paragraph inside Home */
#home p {
    font-family: 'Verdana', sans-serif; /* Custom font style for <p> */
    font-size: 32px; /* Smaller font size for <p> */
    color: #dbf3a2; /* Darker color for <p> */
    margin-top: 15px; /* Space above the paragraph */
    line-height: 1.6; /* Improves readability */

    /* Animation properties */
    animation: fadeInUp 1s ease-in-out;
}

/* Navigation Buttons */
button.prev,
button.next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    border-radius: 5px;
    z-index: 2;
}

button.prev {
    left: 10px; /* Position to the left */
}

button.next {
    right: 10px; /* Position to the right */
}

button.prev:hover,
button.next:hover {
    background-color: rgba(0, 0, 0, 0.8); /* Darker background on hover */
}



#about {
    font-family: Arial, sans-serif; /* Font style */
    font-size: 18px; /* Font size */
    color: #333; /* Font color */
    background-color: #dadfdf; /* Light background for contrast */
    padding: 20px; /* Spacing around the text */
    border-radius: 8px; /* Rounded corners */
    text-align: center;
}


#about h2 {
    font-family: 'Georgia', serif;
    color: #007BFF; /* Font color for the heading */
    font-size: 24px; /* Font size for the heading */
    margin-bottom: 15px;
}

#about p {
    font-family: 'Verdana', sans-serif;
    font-size: 20px;
    padding: 20px; /* Spacing around the text */
    color: #333;
    margin-top: 15px;
    line-height: 1.6; /* Improves readability */
    text-align: center; /* Center the text */
}

#about button {
    margin-top: 20px;
    padding: 10px 20px;
    font-size: 16px;
    color: #fff;
    background-color: #007BFF;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

#about button:hover {
    background-color: #0056b3;
}

.animated-large-heading {
    font-size: 3.5rem;
    font-weight: bold;
    text-align: center;
    color: #6eda58;
    animation: textGrow 2s infinite;
}

@keyframes textGrow {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
}
/* Inventory Section */
.scrollable-list {
    display: flex; /* Makes items align horizontally */
    gap: 1rem; /* Adds space between items */
    overflow-x: auto; /* Enables horizontal scrolling */
    padding: 1rem; /* Adds padding around the list */
    scroll-behavior: smooth; /* Smooth scrolling effect */
}
.scrollable-list::-webkit-scrollbar {
    height: 20px; /* Adjust the height of the scrollbar */
}
.scrollable-list::-webkit-scrollbar-thumb {
    background-color: #3982f0; /* Scrollbar color */
    border-radius: 10px; /* Rounded corners */
}
.scrollable-list::-webkit-scrollbar-thumb:hover {
    background-color: #e6dede; /* Color on hover */
}
.car-item {
    flex: 0 0 auto; /* Prevents items from shrinking or growing */
    text-align: center;
    width: 200px; /* Adjust the size of each item */
    margin: 20px;
    border: 1px solid #ccc; /* Optional: border around each item */
    border-radius: 10px;
    padding: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* Optional: subtle shadow */
    transition: transform 0.3s ease;
}

.car-listing {
    display: flex;
    justify-content: space-evenly;
    margin-top: 20px;
    color: white;
}

.car-item img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
    margin-bottom: 0.5rem;
    transition: transform 0.3s ease;
}

.car-item:hover {
    transform: scale(1.05);
}

.car-item button {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px;
    cursor: pointer;
    margin-top: 10px;
    transition: background-color 0.3s ease;
}

.car-item button:hover {
    background-color: #45a049;
}

/* Chat Popup */
.chat-popup {
    position: fixed;
    bottom: 10px;
    right: 10px;
    width: 300px;
    background-color: #f1f1f1;
    border: 1px solid #ccc;
    padding: 10px;
    display: none;
    z-index: 1000;
    animation: slideIn 0.5s ease;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    font-weight: bold;
}

.chat-body {
    margin-top: 10px;
    max-height: 200px;
    overflow-y: auto;
}

.chat-body input {
    width: 100%;
    padding: 10px;
}

.chat-btn {
    position: fixed;
    bottom: 10px;
    right: 10px;
    background-color: #4CAF50;
    color: white;
    padding: 10px;
    border: none;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

/* CSS for Contact Form */
/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #fff;
    padding: 20px;
    border-radius: 10px;
    width: 80%;
    max-width: 500px;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.modal-content h2 {
    margin-top: 0;
}

.modal-content label {
    display: block;
    margin: 10px 0 5px;
}

.modal-content input,
.modal-content textarea {
    width: 95%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.modal-content button {
    padding: 10px 20px;
    background-color: #007BFF;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.modal-content button:hover {
    background-color: #0056b3;
}

/* Close button */
.modal-content .close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
}


/* Modal Styling */
.modal {
    display: none; /* Hide by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent background */
    justify-content: center;
    align-items: center;
    z-index: 1000; /* Ensure it appears above other elements */
}

.modal-content {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    max-width: 400px;
    margin: auto;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

button {
    margin-top: 10px;
    padding: 10px 20px;
    font-size: 16px;
    background-color: #007BFF;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

button:hover {
    background-color: #0056b3;
}

.map-container {
    margin: 20px auto;
    text-align: center;
    background-color: #8c918b;
}
/* Review Section */

.reviews {
    display:flex;               /* Align children (reviews) in a row */
    overflow-x: scroll;            /* Hide overflow to make it a "slider" */
    position: relative;
}

.review {
    display: inline-block;       /* Keeps reviews in a horizontal line */
    width: 200px;                /* Adjust the width of each review */
    margin-right: 20px;          /* Optional: Adds space between reviews */
    text-align: center;          /* Centers the images and text */
}

buttonR {
    position: absolute;
    top: 50%;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 10px;
    border: none;
    cursor: pointer;
    z-index: 10;
    transform: translateY(-50%);
}

a {
    font-size: 16px;
    color: #007BFF;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

#about h3 {
    margin-top: 20px;
    color: #333;
}

.prev, .next {
    position: absolute;          /* Positions the buttons on the left and right */
    top: 50%;
    transform: translateY(-50%); /* Centers the buttons vertically */
    background-color: rgba(0, 0, 0, 0.5); /* Optional: Dark background for buttons */
    color: white;                /* White color for arrows */
    padding: 10px;               /* Adds space around the arrows */
    border: none;                /* Removes default button styles */
    cursor: pointer;            /* Changes the cursor to indicate it's clickable */
    z-index: 2;                  /* Makes sure buttons are above the reviews */
}
.prev {
    left: 10px;                  /* Positions the left button */
}

.next {
    right: 10px;                 /* Positions the right button */
}

.prev:hover, .next:hover {
    background-color: rgba(0, 0, 0, 0.8); /* Darker background on hover */
}


.center-link {
    display: flex;
    justify-content: center;  /* Centers the content horizontally */
    align-items: center;      /* Centers the content vertically */
    margin-top: 20px;         /* Optional: Adds space above the link */
}

.center-link a {
    font-size: 16px;
    color: #007BFF;
    text-decoration: none;
}

.center-link a:hover {
    text-decoration: underline;
}

/* Modal Container for view car details */
.modal {
    display: none; /* Hidden by default */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8); /* Dimmed background */
    justify-content: center;
    align-items: center;
}

/* Modal Content */
.modal-content {
    background-color: #fff;
    padding: 30px; /* Increased padding for better spacing */
    border-radius: 20px; /* Rounded corners */
    max-width: 800px; /* Larger max-width */
    width: 90%;
    box-shadow: 0px 6px 15px rgba(0, 0, 0, 0.3);
    animation: slideDown 0.3s ease-in-out;
    position: relative;
    overflow: hidden; /* Prevent content overflow */
}

/* Modal Header */
.modal-header h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
    font-size: 28px; /* Larger font for the header */
}

/* Modal Body Image */
.modal-body img {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 20px;
    max-height: 400px; /* Limit image height */
    object-fit: cover; /* Ensure the image fits nicely */
}

/* Footer */
.modal-footer {
    text-align: right;
    margin-top: 20px;
}

.modal-footer button {
    padding: 12px 24px;
    border: none;
    background-color: #007bff;
    color: white;
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
}

.modal-footer button:hover {
    background-color: #0056b3;
}

/* Carousel */

.carousel {
    position: relative;
    display: flex; /* Center horizontally */
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.carousel img {
    max-width: 100%;
    border-radius: 10px;
    max-height:500px; /* Increased image size */
    height: auto;
}

/* Navigation Controls */
.carousel-control {
    position: absolute;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    font-size: 24px;
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    border-radius: 50%;
    z-index: 10;
}

.carousel-control.prev {
    left: 10px;
}

.carousel-control.next {
    right: 10px;
}

.carousel-control:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

/* Table Styles */
.details-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    height: auto; /* Let it adjust to content */
}

.details-table td {
    border: 1px solid #ddd;
    padding: 8px; /* Reduced padding */
    font-size: 13px; /* Smaller text */
}

.details-table td:first-child {
    font-weight: bold;
    background-color: #f9f9f9;
    white-space: nowrap; /* Prevents text from wrapping */
}

.details-table tr:nth-child(even) {
    background-color: #f2f2f2;
}

.details-table tr:hover {
    background-color: #ddd;
}

/* Close Button */
.close {
    font-size: 30px;
    position: absolute;
    top: 15px;
    right: 25px;
    cursor: pointer;
    color: #555;
    transition: color 0.3s ease;
}

.close:hover {
    color: #000;
}


/* Animation */
@keyframes slideUp {
    from {
        transform: translate(50%, 50%);
        opacity: 0;
    }
    to {
        transform: translate(-50%, -50%);
        opacity: 1;
    }
}

/* Apply animation to the element */
.modal {
    position: fixed;
    bottom: 0;
    top: 50%;
    left: 50%;
    right: 0;
    transform: translate(-50%, -50%);
    width: 100%; /* Adjust as needed */
    max-width: 1000px; /* Limit max size for larger screens */
    height: 95vh; /* Adjust as needed */
    max-height: 200vh; /* Avoid overflow on smaller screens */
    background: transparent;
    padding: 20px;
    border-radius: 10px;
    opacity: 0;
    animation: slideUp 0.5s forwards;
    transform: translate(50%, 50%);
    overflow: auto;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .modal {
        width: 85%; /* Adjust width for tablets and smaller screens */
        max-width: 1000px;
    }
}

@media (max-width: 480px) {
    .modal {
        width: 95%; /* Use more screen space for mobile */
        max-width: 900px;
        padding: 15px;
    }
}

/* Price Section */
.price-section {
    text-align: center;
    margin-bottom: 20px;
}

.animated-price {
    font-size: 40px;
    font-weight: bold;
    color: #ff5733;
    animation: pulse 1.5s infinite ease-in-out;
}

/* Pulse Animation */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
}

/* General Styles - Responsive CSS script */
body {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.header {
    width: 100%;
    text-align: center;
    padding: 20px;
    background-color: #333;
    color: white;
}

.card {
    flex: 1 1 300px;
    max-width: 350px;
    margin: 10px;
    padding: 20px;
    background-color: #f4f4f4;
    border-radius: 10px;
    text-align: center;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .container {
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 768px) {
    .header {
        font-size: 1.5rem;
        padding: 15px;
    }

    .card {
        max-width: 90%;
    }
}



