/*
Theme Name: Carbazzar Premium
Author: Raj
Description: A premium light-mode theme for Carbazzar.co.in
Version: 1.4
*/

/* === RESET & BASE STYLES === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: #f9f9f9; /* Light background */
    color: #333333; /* Dark text for readability */
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* === NAVBAR (LIGHT GLASSMORPHISM) === */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 5%;
    position: absolute; /* Pages handle fixed/absolute positioning as needed */
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95); /* Light transparent background */
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid #eaeaea;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03); /* Soft premium shadow */
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.logo a {
    font-size: 26px;
    font-weight: 700;
    color: #111; /* Dark logo text */
    letter-spacing: 1px;
}

.logo span {
    color: #e50914; 
}

/* Wrapper for both Links and Login button */
.nav-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 25px;
    margin: 0 auto;
}

.nav-item {
    position: relative;
    padding: 10px 0;
}

.nav-item > a {
    font-size: 16px;
    font-weight: 500;
    color: #333;
    transition: color 0.3s ease;
}

.nav-item > a:hover {
    color: #e50914;
}

/* Dropdown Menu Setup */
.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: #ffffff; /* White background */
    min-width: 220px;
    border-radius: 12px;
    border: 1px solid #eaeaea;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 15px 35px rgba(0,0,0,0.05); /* Light premium shadow */
    padding: 10px 0;
    z-index: 100;
}

.nav-item:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown li a {
    display: block;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    color: #555; /* Dark gray for dropdown text */
    transition: all 0.3s ease;
    white-space: nowrap;
}

.dropdown li a:hover {
    background: #f4f6f9; /* Light hover background */
    color: #e50914;
    padding-left: 25px; /* Subtle indent effect on hover */
}

/* Dynamic Button (Login / Sell Your Car) */
.login-btn {
    background: linear-gradient(45deg, #e50914, #ff4b2b);
    color: white !important;
    padding: 10px 25px;
    border-radius: 30px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(229, 9, 20, 0.25);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
    white-space: nowrap; /* Prevents text from wrapping when it changes to 'Sell Your Car' */
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(229, 9, 20, 0.4);
}

/* Hide Hamburger Menu on Desktop */
.mobile-menu-btn {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    z-index: 1001;
}

.mobile-menu-btn span {
    width: 28px;
    height: 3px;
    background-color: #111; /* Dark hamburger icon */
    border-radius: 3px;
    transition: 0.3s ease;
}

/* === HERO SECTIONS (General) === */
.hero {
    height: 45vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 0 20px;
    border-bottom: 1px solid #eaeaea;
}

.hero-content {
    margin-top: 60px;
}

.welcome-badge {
    display: inline-block;
    background: rgba(229, 9, 20, 0.1);
    color: #e50914;
    padding: 8px 20px;
    border-radius: 30px;
    border: 1px solid rgba(229, 9, 20, 0.3);
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 20px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.hero-content h1 {
    font-size: 50px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #111; 
    letter-spacing: 1px;
}

.hero-content h1 span {
    color: #e50914;
}

.hero-content p {
    font-size: 18px;
    color: #555;
    margin-bottom: 40px;
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
}

/* === CONTENT CONTAINERS === */
.page-content-wrapper {
    padding: 60px 5% 100px;
    background: #f9f9f9;
}

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

.section-header {
    margin-bottom: 40px;
    text-align: center;
}

.section-header h2 {
    font-size: 32px;
    color: #111;
    margin-bottom: 10px;
    font-weight: 700;
}

.section-header p {
    color: #777;
    font-size: 16px;
}

/* =========================================
   CAR SLIDER & GRID SYSTEM
   ========================================= */

/* Global Image Fix */
.car-slider img,
.site-content img,
.posts-grid img,
.carbazzar-car-grid img {
    width: 100% !important;
    height: 250px !important;
    object-fit: cover !important;
    display: block;
    border-radius: 12px 12px 0 0;
    border-bottom: 3px solid #e50914;
}

/* Slider Track Settings */
.car-slider {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    gap: 20px;
    padding: 15px 5px 30px;
    -ms-overflow-style: none; /* IE and Edge */
    scrollbar-width: none; /* Firefox */
}

.car-slider::-webkit-scrollbar {
    display: none; /* Chrome, Safari and Opera */
}

/* Slider Items (Light Theme Cards) */
.car-slider > * {
    flex: 0 0 calc(25% - 15px) !important;
    max-width: calc(25% - 15px) !important;
    box-sizing: border-box;
    background: #ffffff; /* White card */
    border: 1px solid #eaeaea;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease, border-color 0.3s ease;
}

.car-slider > *:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
    border-color: rgba(229, 9, 20, 0.4);
}

/* See All Button */
.see-all-btn {
    color: #e50914;
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;
    border: 2px solid #e50914;
    padding: 10px 28px;
    border-radius: 30px;
    transition: all 0.3s ease;
    display: inline-block;
}

.see-all-btn:hover {
    background: #e50914;
    color: #fff;
    box-shadow: 0 5px 15px rgba(229, 9, 20, 0.2);
}

/* === FOOTER (SOFT DARK THEME) === */
footer {
    background: #1c1e24; /* Soft dark */
    padding: 80px 5% 30px;
    color: #bbbbbb;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col {
    flex: 1;
    min-width: 200px;
}

.footer-col h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: #ffffff;
    font-weight: 600;
}

.footer-col p, .footer-col a {
    color: #bbbbbb;
    font-size: 14px;
    margin-bottom: 12px;
    display: block;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-col a:hover {
    color: #e50914;
}

.copyright {
    text-align: center;
    color: #888888;
    font-size: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    margin-top: 50px;
}

/* =========================================
   MOBILE RESPONSIVENESS
   ========================================= */

/* Tablet Optimization for Slider */
@media screen and (max-width: 1024px) {
    .car-slider > * {
        flex: 0 0 calc(33.333% - 15px) !important; /* 3 cars per line */
        max-width: calc(33.333% - 15px) !important;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 15px 20px;
        flex-wrap: nowrap;
    }

    /* Show Hamburger Menu */
    .mobile-menu-btn {
        display: flex;
    }

    /* Nav Wrapper handles both links and login */
    .nav-wrapper {
        display: none;
        flex-direction: column;
        width: 100%;
        background: #ffffff; /* Light background for mobile menu */
        position: absolute;
        top: 100%;
        left: 0;
        padding: 20px 5% 30px;
        z-index: 1000;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        border-top: 1px solid #eaeaea;
    }

    .nav-wrapper.active {
        display: flex;
    }

    /* Reset Nav Links */
    .nav-links {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 15px;
        margin: 0;
    }

    .nav-item {
        margin: 0;
        width: 100%;
    }

    /* Dropdown inside Mobile Menu */
    .dropdown {
        position: relative;
        display: none; /* Controlled via hover/active in CSS or JS */
        background: #f9f9f9;
        padding: 5px 0 5px 15px;
        margin-top: 5px;
        border-left: 2px solid #e50914;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border-top: none;
        border-right: none;
        border-bottom: none;
    }

    .nav-item:hover .dropdown, 
    .nav-item:active .dropdown {
        display: block;
    }

    /* Mobile Login Button Adjustment */
    .login-btn {
        margin-top: 15px;
        display: block;
        text-align: center;
        width: 100%;
    }
    
    .hero-content h1 {
        font-size: 36px;
    }
    
    .hero-content p {
        font-size: 16px;
    }

    /* Mobile Slider Adjustments - Vertical List */
    .car-slider {
        flex-direction: column; /* Switch to vertical list view on mobile */
        overflow-x: hidden;
        gap: 30px;
        padding: 10px 0;
    }
    .car-slider > * {
        flex: 0 0 100% !important; /* Display 1 car per row on mobile */
        max-width: 100% !important;
    }
    
    /* Ensure Footer items stack perfectly */
    .footer-container {
        display: flex;
        flex-direction: column;
        gap: 30px;
    }

    .footer-col {
        width: 100%;
        text-align: left;
    }
}