/*
Theme Name: CarSparrow Premium
Theme URI: https://carsparrow.com
Author: Antigravity
Description: Premium modern automotive guide theme.
Version: 1.0.0
Text Domain: carsparrow
*/

:root {
    --bg-main: #f5f4ef;
    --accent: #bfbeb7;
    /* Light Stone/Grey */
    --accent-soft: rgba(191, 190, 183, 0.2);
    --glass: rgba(255, 255, 255, 0.7);
    --border: rgba(0, 0, 0, 0.08);
    --text-main: #1a1a1a;
    --text-muted: #666;
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.05);
    --radius-full: 100px;
    --radius-lg: 32px;
    --radius-md: 16px;
    --card-bg: #fefff5;
    --header-bg: #f2f1e8;
}


html.dark-mode body,
body.dark-mode {
    --bg-main: #141416;
    --accent: #e5e0b7;
    /* Creamy Accents */
    --accent-soft: rgba(229, 224, 183, 0.15);
    --glass: rgba(30, 30, 32, 0.8);
    --border: rgba(255, 255, 255, 0.05);
    --text-main: #f5f4ef;
    --text-muted: #8e8e93;
    --shadow-soft: 0 20px 50px rgba(0, 0, 0, 0.4);
    --card-bg: #232326;
    --header-bg: #1c1c1e;
}






* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--header-bg);
    font-family: 'Outfit', sans-serif;
    color: var(--text-main);
    min-height: 100vh;
    padding: 0;
    overflow-x: hidden;
    transition: background-color 0.4s ease, color 0.4s ease;
}

.search-results-page {
    background-color: var(--header-bg);
    transition: background-color 0.4s ease;
}



/* Global Utilities */
.text-left { text-align: left !important; }
.text-center { text-align: center !important; }
.text-right { text-align: right !important; }

.mb-1 { margin-bottom: 1rem !important; }
.mb-2 { margin-bottom: 2rem !important; }
.mb-3 { margin-bottom: 3rem !important; }
.mb-4 { margin-bottom: 4rem !important; }

.pos-relative { position: relative !important; }

.main-wrapper {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 6rem 2rem 6rem;
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
    /* Prevent horizontal scroll from any child */
}


@media (max-width: 768px) {
    .main-wrapper {
        padding: 0 1rem 2rem 1rem !important;
        /* Reduced side padding slightly more */
    }

    .home-container {
        padding: 0.6rem 1rem !important;
        border-radius: 0 !important;
        margin-top: 0 !important;
    }

    .home-topbar {
        padding: 1rem 1.5rem !important;
        /* Increased header side padding */
    }

    .brands-header-flex {
        padding: 1rem 0 !important;
        margin-bottom: 2rem !important;
        margin-top: -1rem !important;
        /* Tighter top gap */
    }
}


/* Header & Sidebar Combined */
.header {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 4rem;
    margin-bottom: 5rem;
}

.sidebar {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.logo {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    font-weight: 900;
    letter-spacing: -1px;
    margin-bottom: 2.5rem;
    background: linear-gradient(135deg, #000 0%, #444 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-menu {
    background: var(--glass);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    box-shadow: var(--shadow-soft);
}

.nav-btn {
    border: none;
    background: transparent;
    padding: 1rem;
    font-family: inherit;
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-main);
    cursor: pointer;
    border-radius: 12px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.nav-btn.active {
    background: var(--accent);
    color: white;
    box-shadow: 0 10px 20px -5px rgba(0, 0, 0, 0.2);
}

.nav-sep {
    height: 1px;
    background: var(--border);
    margin: 0.25rem 0.5rem;
}

.search-trigger {
    width: 50px;
    height: 50px;
    border-radius: 15px;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-trigger:hover {
    transform: scale(1.05);
    background: var(--accent);
    color: white;
}

/* Featured Section */
.hero-section {
    position: relative;
}

.featured-cards-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.feature-card {
    position: relative;
    aspect-ratio: 1/1;
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    box-shadow: var(--shadow-soft);
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
    animation-delay: var(--delay);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.image-wrapper {
    width: 100%;
    height: 100%;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feature-card:hover .image-wrapper {
    transform: scale(1.08);
}

.card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: white;
    transform: translateY(10px);
    opacity: 0;
    transition: all 0.4s ease;
}

.feature-card:hover .card-overlay {
    transform: translateY(0);
    opacity: 1;
}

.car-tag {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
    display: block;
    font-weight: 300;
}

.car-name {
    font-size: 1.5rem;
    font-weight: 600;
}

/* Popular Categorized Section */
.popular-section {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    padding: 1.5rem 0;
    margin-bottom: 6rem;
    box-shadow: var(--shadow-soft);
}

.tabs-header {
    display: flex;
    gap: 2.5rem;
    padding: 0 2.5rem 1rem 2.5rem;
    border-bottom: 1px solid var(--border);
    overflow-x: auto;
    scrollbar-width: none;
}

.tab-btn {
    background: none;
    border: none;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.5rem 0;
    white-space: nowrap;
    position: relative;
    transition: all 0.3s ease;
}

.tab-btn.active {
    color: var(--accent);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--accent);
    border-radius: 10px;
}

.popular-rows {
    display: flex;
    flex-direction: column;
}

.category-row {
    display: flex;
    align-items: center;
    padding: 1.5rem 2.5rem;
    transition: background 0.3s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.category-row:last-child {
    border-bottom: none;
}

.category-row:hover {
    background: #fafaf9;
}

.row-label {
    min-width: 100px;
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--text-main);
    text-transform: uppercase;
}

.row-content {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 1rem;
    position: relative;
    overflow: hidden;
}

.cars-scroll {
    flex: 1;
    display: flex;
    gap: 3rem;
    overflow-x: auto;
    scrollbar-width: none;
    padding: 0.5rem 0;
}

.cars-scroll::-webkit-scrollbar {
    display: none;
}

.car-item {
    text-align: center;
    min-width: 140px;
}

.car-item-title {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-main);
}

.car-item-links {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.car-item-links a {
    text-decoration: none;
    color: #999;
    transition: color 0.3s ease;
}

.car-item-links a:hover {
    color: var(--accent);
}

.sep {
    color: #eee;
}

.nav-arrow {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #ccc;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.nav-arrow:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

@media (max-width: 768px) {
    .popular-section {
        border-radius: 0;
        margin-left: -1.5rem;
        margin-right: -1.5rem;
        padding: 1rem 0;
    }

    .tabs-header {
        padding: 0 1.5rem 1rem 1.5rem;
    }

    .category-row {
        flex-direction: column;
        align-items: flex-start;
        padding: 1.5rem;
        gap: 1rem;
    }

    .row-label {
        font-size: 1rem;
    }

    .nav-arrow {
        display: none;
    }

    .cars-scroll {
        gap: 2rem;
    }
}

/* Popular Cars Grid (3x3) */
.popular-cars-grid-section {
    margin-bottom: 6rem;
}

.sub-column {
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.5rem;
}

.sub-title {
    font-size: 0.9rem;
    font-weight: 800;
    color: var(--text-main);
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.content-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.column-header {
    margin-bottom: 2rem;
    position: relative;
}

.column-title {
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
}

.title-accent {
    width: 40px;
    height: 3px;
    background: var(--accent);
    margin-top: 0.5rem;
    border-radius: 10px;
}

.list-container {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.glass-list-item {
    background: white;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.glass-list-item:hover {
    border-color: var(--accent);
    transform: translateX(8px);
    box-shadow: 10px 10px 30px rgba(0, 0, 0, 0.03);
}

.item-number {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    opacity: 0.5;
}

.item-text {
    flex: 1;
    font-weight: 600;
    font-size: 1rem;
}

.item-arrow {
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s ease;
}

.glass-list-item:hover .item-arrow {
    opacity: 1;
    transform: translateX(0);
}

/* Responsive */
@media (max-width: 1024px) {
    .header {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .sidebar {
        flex-direction: row;
        align-items: center;
    }

    .logo {
        margin-bottom: 0;
    }

    .nav-menu {
        flex-direction: row;
    }

    .content-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

/* Mobile Navigation */
.mobile-header {
    display: none;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background: var(--bg-main);
    position: sticky;
    top: 0;
    z-index: 1001;
    border-bottom: 1px solid var(--border);
}

.hamburger {
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1002;
}

.hamburger span {
    display: block;
    width: 28px;
    height: 3px;
    background: var(--accent);
    border-radius: 10px;
    transition: all 0.3s ease;
}

/* Hamburger Open States */
.hamburger.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background: white;
    z-index: 1000;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(10px);
}

.mobile-menu.active {
    right: 0;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    text-align: center;
}

.mobile-nav-link {
    font-size: 2rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--text-main);
    font-family: 'Playfair Display', serif;
    transition: all 0.3s ease;
}

.mobile-nav-link:hover {
    color: var(--accent);
    transform: scale(1.1);
}

@media (max-width: 1024px) {
    .main-wrapper {
        padding: 1rem 1.5rem;
    }

    .theme-header.classic-layout {
        display: none !important;
    }

    .mobile-header {
        display: flex !important;
    }

    .nav-list {
        display: none;
    }

    .featured-cards-container {
        grid-template-columns: 1fr;
    }
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.modal-content {
    background-color: white;
    margin: 10% auto;
    padding: 3rem;
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 600px;
    box-shadow: 0 50px 100px rgba(0, 0, 0, 0.3);
    position: relative;
    transform: translateY(0);
    animation: slideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.hidden {
    display: none !important;
}

.specs-step-box {
    animation: fadeIn 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    margin-bottom: 4rem;
}

.sub-step-title {
    font-size: 1.8rem;
    font-weight: 900;
    margin: 1rem 0 2rem 0;
    font-family: 'Playfair Display', serif;
}

.engine-selection-header,
.content-header {
    text-align: center;
    margin-top: 3rem;
}

@keyframes slideIn {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close {
    position: absolute;
    right: 2rem;
    top: 2rem;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-muted);
}

.close:hover {
    color: var(--accent);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-main);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* Footer */
.footer {
    margin-top: 8rem;
    padding-top: 4rem;
    padding-bottom: 4rem;
    border-top: 1px solid var(--border);
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 4rem;
}

.footer-brand .logo {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

/* Header & Hero Layout */
.theme-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 2rem 0;
    margin-bottom: 4rem;
}

.sidebar-brand {
    display: flex;
    flex-direction: column;
    gap: 4rem;
    min-width: 250px;
}

.brand-section .logo {
    font-size: 4rem;
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    letter-spacing: -2px;
}

.brand-section .logo a {
    text-decoration: none;
    color: var(--text-main);
}

.header-search {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.search-box {
    width: 280px;
    height: 45px;
    background: #f9f9f7;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.search-icon-btn {
    width: 50px;
    height: 50px;
    background: white;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    color: var(--text-main);
}

.hero-showcase {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.featured-cards-container {
    display: flex;
    gap: 2rem;
}

.feature-card {
    width: 320px;
    height: 320px;
    border-radius: 50px;
    overflow: hidden;
    background: #eee;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
}

.feature-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

@media (max-width: 1200px) {
    .theme-header {
        flex-direction: column;
        gap: 3rem;
    }

    .hero-showcase {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .featured-cards-container {
        flex-direction: column;
        align-items: center;
    }

    .feature-card {
        width: 100%;
        max-width: 400px;
    }
}

.footer-desc {
    color: var(--text-muted);
    line-height: 1.7;
    max-width: 320px;
    font-size: 0.95rem;
}

.footer-title {
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-links a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--accent);
    transform: translateX(5px);
}

.footer-bottom {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.social-links {
    display: flex;
    gap: 1.5rem;
}

.social-links svg {
    cursor: pointer;
    transition: color 0.3s ease;
}

.social-links svg:hover {
    color: var(--accent);
}

@media (max-width: 1024px) {
    .footer {
        grid-template-columns: 1fr 1fr;
        gap: 3rem;
    }
}

@media (max-width: 768px) {
    .footer {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-desc {
        margin: 0 auto;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1.5rem;
    }
}

/* Blog Section */
.blog-section {
    margin-bottom: 8rem;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.blog-card {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    overflow: hidden;
    transition: all 0.4s ease;
    box-shadow: var(--shadow-soft);
}

.blog-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
    border-color: var(--accent);
}

.post-thumbnail img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.blog-card:hover .post-thumbnail img {
    transform: scale(1.05);
}

.post-content {
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    flex: 1;
}

.entry-title {
    font-size: 1.6rem;
    font-family: 'Playfair Display', serif;
    font-weight: 800;
    line-height: 1.3;
}

.entry-title a {
    text-decoration: none;
    color: var(--text-main);
    transition: color 0.3s ease;
}

.entry-title a:hover {
    color: var(--accent);
}

.entry-excerpt {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .blog-grid {
        grid-template-columns: 1fr;
    }
}

/* Single Post & Page Reading View */
.single-post-container {
    padding-top: 0;
}

.post-hero {
    position: relative;
    height: 45vh;
    min-height: 400px;
    display: flex;
    align-items: flex-end;
    padding: 6rem 4rem;
    overflow: hidden;
    margin-bottom: -4rem;
    background: var(--bg-main);
    /* Fallback */
}

.post-hero.has-image {
    background: #000;
}

.post-hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.post-hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.7);
    opacity: 0.8;
}

.post-hero-content {
    max-width: 900px;
    color: var(--text-main);
    z-index: 1;
    position: relative;
}

.post-hero.has-image .post-hero-content {
    color: white;
}

.post-title {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    line-height: 1.1;
    margin-top: 1rem;
    color: inherit;
}

.post-meta {
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.post-meta a {
    color: var(--accent);
    text-decoration: none;
}

.post-author-meta {
    margin-top: 1rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--accent);
    background: var(--accent-soft);
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 8px;
}

.post-hero.has-image .post-author-meta {
    color: white;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
}

.post-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 4rem;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 2;
}

.post-entry-content {
    background: white;
    padding: 4rem;
    border-radius: var(--radius-lg);
    line-height: 1.8;
    font-size: 1.15rem;
    box-shadow: var(--shadow-soft);
}

.post-entry-content p {
    margin-bottom: 2rem;
}

.post-entry-content h2,
.post-entry-content h3 {
    margin: 3rem 0 1.5rem 0;
    font-family: 'Playfair Display', serif;
}

.sidebar-widget {
    background: white;
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    position: sticky;
    top: 100px;
}

@media (max-width: 1024px) {
    .post-content-wrapper {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 768px) {
    .post-hero {
        height: 50vh;
        padding: 2rem;
    }

    .post-entry-content {
        padding: 2rem;
        border-radius: 0;
    }
}

/* Homepage Hero Header Layout - Restoration */
.home-hero-wrapper {
    padding: 3rem 0 5rem 0;
}

.hero-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    /* Increased sidebar width */
    gap: 3rem;
    align-items: start;
}

.hero-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    /* Tighter gap for better fit */
}

.hero-brand .logo {
    font-size: 3.2rem;
    /* Slightly smaller to fit better */
    font-weight: 900;
    font-family: 'Playfair Display', serif;
    letter-spacing: -2px;
    line-height: 1;
}

.site-slogan {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 5px;
}

.hero-brand .logo a {
    text-decoration: none;
    color: var(--text-main);
}

.shadow-card {
    background: white;
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.hero-nav-card {
    width: 200px;
    padding: 12px;
}

.nav-card-inner {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-btn-pill {
    background: #1a1a1a;
    color: white;
    text-align: center;
    padding: 12px;
    border-radius: 16px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.nav-btn-text {
    color: var(--text-main);
    text-align: center;
    padding: 12px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
}

/* Homepage Hero Header Layout - Sidebar Style */
.home-hero-wrapper {
    padding: 3rem 0 5rem 0;
}

.hero-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 4rem;
    align-items: start;
}

.hero-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.hero-brand .logo {
    font-size: 3.2rem;
    font-weight: 900;
    font-family: 'Playfair Display', serif;
    letter-spacing: -2px;
    line-height: 1;
}

.hero-brand .logo a {
    text-decoration: none;
    color: var(--text-main);
}

.site-slogan {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 5px;
}

.shadow-card {
    background: white;
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.hero-nav-card {
    width: 200px;
    padding: 12px;
}

.nav-card-inner {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-btn-pill {
    background: #1a1a1a;
    color: white;
    text-align: center;
    padding: 12px;
    border-radius: 16px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.nav-btn-text {
    color: var(--text-main);
    text-align: center;
    padding: 12px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
}

.hero-search-box {
    width: 200px;
    padding: 8px 12px;
    border-radius: 16px;
}

.hero-search-form {
    display: flex;
    align-items: center;
    gap: 5px;
}

.hero-search-input {
    border: none;
    background: transparent;
    width: 100%;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
}

.hero-search-input:focus {
    outline: none;
}

.hero-search-submit {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--text-muted);
    padding: 0;
    display: flex;
    align-items: center;
}

.hero-showcase {
    flex: 1;
}

.showcase-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.showcase-item {
    aspect-ratio: 1/1.1;
    border-radius: 40px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    background: #f0f0f0;
}

.showcase-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.showcase-item:hover img {
    transform: scale(1.05);
}

.showcase-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2rem;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    color: white;
}

.sc-tag {
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    background: var(--accent);
    padding: 3px 8px;
    border-radius: 4px;
}

.sc-title {
    font-size: 1.2rem;
    font-weight: 900;
    margin-top: 5px;
    font-family: 'Playfair Display', serif;
}

/* Standard Header (Initially hidden on home page top) */
.site-header-standard {
    position: fixed;
    top: -100px;
    /* Hidden initially */
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--border);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    padding: 1.2rem 4rem;
}

/* When scrolling OR on other pages */
body:not(.home) .site-header-standard,
body.is-scrolled .site-header-standard {
    top: 0;
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-mini a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 900;
    font-size: 1.8rem;
    font-family: 'Playfair Display', serif;
}

.nav-list-classic {
    display: flex;
    gap: 3rem;
    list-style: none;
}

.nav-list-classic a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
}

.icon-btn-square {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    color: var(--text-main);
    border-radius: 14px;
}

/* NEW: Hero Search Box Open Style */
.hero-search-box {
    width: 200px;
    padding: 8px 12px;
    border-radius: 16px;
}

.hero-search-form {
    display: flex;
    align-items: center;
    gap: 5px;
}

.hero-search-input {
    border: none;
    background: transparent;
    width: 100%;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
}

.hero-search-input:focus {
    outline: none;
}

.hero-search-submit {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--text-muted);
    padding: 0;
    display: flex;
    align-items: center;
}

.hero-showcase {
    flex: 1;
}

.showcase-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.showcase-item {
    aspect-ratio: 1/1.1;
    border-radius: 40px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    background: #e0e0e0;
    position: relative;
}

.showcase-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.showcase-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2rem;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    color: white;
    transform: translateY(10px);
    transition: all 0.4s ease;
}

.showcase-item:hover .showcase-caption {
    transform: translateY(0);
}

.sc-tag {
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    background: var(--accent);
    padding: 4px 10px;
    border-radius: 6px;
}

.sc-title {
    font-size: 1.2rem;
    font-weight: 900;
    margin-top: 8px;
    font-family: 'Playfair Display', serif;
}

/* Responsive Overrides */
@media (max-width: 1024px) {
    .home-hero-wrapper {
        padding: 1rem 0 3rem 0;
    }

    .hero-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .hero-sidebar {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1.5rem;
        padding: 0 1rem;
    }

    .hero-brand .logo {
        font-size: 3rem;
        margin-bottom: 0.5rem;
    }

    .hero-nav-card {
        display: none;
    }

    .hero-search-box {
        width: 100%;
        max-width: 320px;
    }

    .showcase-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
        padding: 0 1rem;
    }
}

@media (max-width: 768px) {
    .showcase-grid {
        grid-template-columns: 1fr;
    }

    .showcase-item {
        aspect-ratio: 16/9;
    }
}

@media (max-width: 600px) {
    .showcase-grid {
        grid-template-columns: 1fr;
    }

    .showcase-item {
        aspect-ratio: 16/9;
    }
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-mini a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 900;
    font-size: 1.8rem;
    font-family: 'Playfair Display', serif;
}

.nav-list-classic {
    display: flex;
    gap: 3rem;
    list-style: none;
}

.nav-list-classic a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
}

/* Most Clicked Cars Section (Thumbnails) */
.most-clicked-section {
    width: 100%;
    margin-top: 2rem;
}

.section-label {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--text-muted);
    letter-spacing: 2px;
    margin-bottom: 2rem;
    text-align: center;
    opacity: 0.6;
}

.cars-thumb-grid {
    display: flex;
    justify-content: center;
    gap: 4rem;
    flex-wrap: wrap;
}

.car-thumb-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
    animation-delay: var(--delay);
}

.car-thumb-img {
    width: 200px;
    /* Adjust as needed */
    height: auto;
    filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.15));
    transition: transform 0.5s ease;
}

.car-thumb-img img {
    width: 100%;
    height: auto;
    object-fit: contain;
}

.car-thumb-item:hover {
    transform: translateY(-10px);
}

.car-thumb-item:hover .car-thumb-img {
    transform: scale(1.1);
}

.car-thumb-name {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-main);
}

@media (max-width: 1024px) {
    .cars-thumb-grid {
        gap: 2rem;
    }

    .car-thumb-img {
        width: 140px;
    }
}

@media (max-width: 768px) {
    .cars-thumb-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

/* CAR SPECIFICATIONS PAGE STYLES - Tabbed Layout */
.specs-page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    /* Standard desktop padding */
}

.specs-hero-clean {
    text-align: center;
    margin-bottom: 4rem;
}

.specs-badge {
    background: var(--accent);
    color: white;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.specs-page-title {
    font-size: 3.5rem;
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    margin: 1rem 0;
}

.specs-page-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    font-weight: 700;
}

.specs-hero-visual {
    margin: 2rem auto;
    max-width: 600px;
    /* Reduced to normal size */
    position: relative;
    padding: 2rem;
}

.specs-hero-visual img {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 50px rgba(0, 0, 0, 0.15));
}

/* Generation Row Selector - Compact & Horizontal */
.gen-list-horizontal {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.gen-row-btn {
    background: white;
    border: 1px solid var(--border);
    border-radius: 100px;
    /* Capsule form */
    padding: 0.6rem 1.2rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
}

.gen-row-btn:hover {
    transform: translateY(-3px);
    border-color: var(--accent);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.gen-row-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    box-shadow: 0 8px 15px rgba(183, 28, 28, 0.3);
    /* Match accent color shadow */
}

.btn-thumb-mini {
    width: 45px;
    height: 45px;
    background: #f8f8f8;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.btn-thumb-mini img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.gen-label {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text-main);
}

.gen-row-btn.active .gen-label {
    color: white;
}

/* SEO Flood Styling */
.seo-intro-flood {
    max-width: 800px;
    margin: 2rem auto;
    text-align: center;
    line-height: 1.8;
}

.seo-intro-flood p {
    font-size: 1rem;
    color: var(--text-muted);
}

.seo-intro-flood strong {
    color: var(--text-main);
}

@media (max-width: 1024px) {
    .gen-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .gen-grid {
        grid-template-columns: 1fr;
    }
}

/* Generation Selector Styles */
.generation-selector {
    margin: 2rem 0;
}

.gen-tabs {
    display: inline-flex;
    gap: 0.5rem;
    background: #f1f1f1;
    padding: 6px;
    border-radius: 100px;
    /* Capsule style */
}

.gen-tab-btn {
    border: none;
    background: transparent;
    padding: 10px 24px;
    border-radius: 90px;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.3s ease;
}

.gen-tab-btn.active {
    background: white;
    color: var(--text-main);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

/* Engine Selector Tabs */
.engine-tabs-wrapper {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 3rem;
    background: var(--accent-soft);
    padding: 8px;
    border-radius: 20px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.engine-tab-btn {
    border: none;
    background: transparent;
    padding: 12px 24px;
    border-radius: 14px;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-muted);
}

.engine-tab-btn.active {
    background: white;
    color: var(--accent);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.engine-spec-content {
    display: none;
}

.engine-spec-content.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

/* Individual Spec Boxes */
.specs-box-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.spec-info-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 2rem;
    box-shadow: var(--shadow-soft);
    transition: transform 0.3s ease;
}

.spec-info-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent);
}

.spec-info-card.highlight-card {
    background: var(--accent);
    color: white;
    border: none;
}

.card-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 800;
    margin-bottom: 1.5rem;
    padding-bottom: 0.8rem;
    border-bottom: 1px solid var(--border);
    display: block;
}

.highlight-card .card-label {
    border-bottom-color: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
}

.card-rows {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.c-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.c-row span {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
}

.highlight-card .c-row span {
    color: rgba(255, 255, 255, 0.6);
}

.c-row strong {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-main);
}

.highlight-card .c-row strong {
    color: white;
}

/* Common Specs Section */
.common-specs-section {
    margin-top: 5rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 900;
    text-align: center;
    margin-bottom: 2rem;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .specs-page-title {
        font-size: 2.5rem;
    }

    .engine-tabs-wrapper {
        flex-direction: column;
        width: 100%;
    }
}

@media (max-width: 1024px) {
    .theme-header.classic-layout {
        display: none;
    }

    .mobile-header {
        display: flex;
    }

    .nav-list {
        display: none;
    }

    .header-top {
        padding: 1rem 0;
    }
}

@media (max-width: 768px) {
    .hero-showcase.classic .featured-cards-container {
        flex-direction: column;
        align-items: center;
    }
}

/* Mobile Header & Menu */
.mobile-header {
    display: none;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: white;
    position: sticky;
    top: 0;
    z-index: 1100;
    border-bottom: 1px solid var(--border);
}

.mobile-header .logo {
    font-size: 1.5rem;
    margin-bottom: 0;
    background: none;
    -webkit-text-fill-color: var(--text-main);
}

.hamburger {
    display: flex;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-main);
    border-radius: 2px;
    transition: 0.3s;
}

.hamburger.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 80%;
    height: 100vh;
    background: white;
    z-index: 1200;
    padding: 4rem 2rem;
    transition: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 20px 0 50px rgba(0, 0, 0, 0.1);
}

.mobile-menu.active {
    left: 0;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.mobile-nav a {
    text-decoration: none;
    color: var(--text-main);
    font-size: 1.3rem;
    font-weight: 700;
}

.main-content-wrapper {
    padding-top: 2rem;
}

/* Brands Page Template */
.brands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}



.brand-glass-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    box-shadow: var(--shadow-soft);
}

.brand-glass-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.06);
    border-color: var(--accent);
}

.brand-name {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-main);
}

.brand-meta {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 5px;
}

.brand-action {
    color: var(--accent);
    opacity: 0.3;
    transition: opacity 0.3s ease;
}

.brand-glass-card:hover .brand-action {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Classic Style Adjustments */
.column-title.classic-style {
    font-size: 0.95rem;
    letter-spacing: 1.5px;
    color: var(--text-main);
    font-weight: 800;
}

.title-accent.mini {
    width: 25px;
    height: 4px;
}

.glass-list-item.mini {
    padding: 1rem 1.25rem;
}

@media (max-width: 1024px) {
    .blog-grid-mini {
        grid-template-columns: 1fr;
    }
}

/* Son Haberler (Latest News Highlights) Styles */
.latest-news-highlights {
    margin-bottom: 5rem;
}

.blog-grid-mini {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
}

.blog-card-mini {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: var(--shadow-soft);
}

.blog-card-mini:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.06);
    border-color: var(--accent);
}

.post-thumb-mini {
    width: 100%;
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
}

.post-thumb-mini img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.blog-card-mini:hover .post-thumb-mini img {
    transform: scale(1.08);
}

.post-content-mini h3 {
    font-size: 1.15rem;
    font-family: 'Playfair Display', serif;
    font-weight: 800;
    line-height: 1.4;
}

.post-content-mini h3 a {
    text-decoration: none;
    color: var(--text-main);
    transition: color 0.3s ease;
}

.post-content-mini h3 a:hover {
    color: var(--accent);
}

.post-meta-mini {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0.5rem;
}

/* =========================================
   NEW HOMEPAGE (OTOPUF PREMIUM) MOCKUP 
   ========================================= */

.home-main {
    background-color: var(--header-bg);
    position: relative;
    z-index: 10;
    padding: 0.5rem 0;
    transition: background-color 0.4s ease;
}

@media (max-width: 1024px) {
    .home-main {
        margin: -1rem -1.5rem;
        padding: 1rem 1.5rem;
    }
}

.home-container {
    max-width: 1200px;
    margin: 0 auto;
    font-family: 'Inter', sans-serif;
    background: var(--header-bg);
    padding: 1rem;
    border-radius: 40px;
    transition: background-color 0.4s ease;
}

/* Global Header Topbar */
.home-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem 4rem;
    /* Reduced padding */
    background: var(--header-bg);
    position: relative;
    z-index: 2000;
    width: 100%;
    max-width: 100%;
    margin-top: 0.5rem;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.02);
    transition: background-color 0.4s ease;
}


.home-topbar-wrapper {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.topbar-logo {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    /* Reduced to 1.5rem */
    font-weight: 900;
    letter-spacing: 2px;
    text-transform: uppercase;
    transform: scaleY(1.3);
    color: var(--accent);
    transition: transform 0.3s ease, color 0.3s ease;
    cursor: pointer;
}


.topbar-logo:hover {
    transform: scaleY(1.3) scaleX(1.05);
    color: var(--text-main);
}

.topbar-nav {
    display: flex;
    gap: 1.5rem;
}

.nav-pill {
    background: var(--card-bg);
    padding: 0.2rem 0.7rem;
    border-radius: 30px;
    font-weight: 700;
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.95rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
}

html.dark-mode .nav-pill,
body.dark-mode .nav-pill {
    background: #252525;
}


.nav-pill:hover,
.nav-pill.active {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
    background: var(--accent);
    color: #1a1a1a;
    /* Dark text on light accent */
}

html.dark-mode .nav-pill.active,
body.dark-mode .nav-pill.active {
    background: var(--accent);
    color: #1c1c1e;
}




.theme-toggle-btn,
.settings-btn {
    padding: 0.2rem 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--card-bg);
    color: var(--text-muted);
}

html.dark-mode .theme-toggle-btn,
html.dark-mode .settings-btn,
body.dark-mode .theme-toggle-btn,
body.dark-mode .settings-btn {
    background: #1a1a1a;
    color: #f2f1e8;
}

@media (max-width: 768px) {

    .home-topbar .theme-toggle-btn,
    .home-topbar .settings-btn {
        display: none;
    }
}



.search-btn {
    background: var(--card-bg);
    color: var(--text-muted);
    padding: 0.2rem 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

html.dark-mode .search-btn,
body.dark-mode .search-btn {
    background: #1a1a1a;
    color: #a0a0a0;
}



.search-btn-icon {
    display: none;
}

.search-btn:hover {
    background: #dfded5;
    color: #333;
}

/* Topbar Actions & Mobile Menu */
.topbar-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.home-hamburger {
    display: none;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    z-index: 4000;
    /* Ensure button is ALWAYS above the menu overlay */
    margin-left: 0.5rem;
}

.home-hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background: var(--text-main);
    border-radius: 3px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}


.home-hamburger.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.home-hamburger.active span:nth-child(2) {
    opacity: 0;
}

.home-hamburger.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* Mobile Menu Setup with Container Scaling */
.home-content-wrapper {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), filter 0.4s ease, border-radius 0.4s ease, background-color 0.4s ease;
    background: var(--header-bg);
    transform-origin: top center;
    border-radius: 20px;
    padding-top: 0.8rem;
    /* Reduced top padding */
}


body.menu-active-bg .home-topbar {
    position: relative;
    z-index: 2100;
    background: var(--header-bg);
}


body.menu-active-bg .home-content-wrapper {
    transform: scale(0.9) translateY(4vh);
    filter: blur(4px) brightness(0.9);
    border-radius: 30px;
    overflow: hidden;
    pointer-events: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
}

.home-mobile-menu,
.home-settings-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3000;
    /* Highest level */
    display: flex;
    justify-content: flex-end;
    align-items: flex-start;
    padding: 20px;
    transition: opacity 0.3s ease, visibility 0.3s;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.home-mobile-menu.active,
.home-settings-menu.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.home-mobile-nav,
.home-settings-content {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    text-align: left;
    background: #1e1e1e;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem 2rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    margin-top: 80px;
    /* Push it down further to be safe */
    margin-right: 50px;
    /* Push it 50px away from the right edge to clear the button */

    /* Android top right popup spawn */
    transform-origin: top right;
    transform: scale(0.8) translateY(-10px);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.home-mobile-menu.active .home-mobile-nav,
.home-settings-menu.active .home-settings-content {
    transform: scale(1) translate(0, 0);
    opacity: 1;
}

.home-mobile-nav .mobile-nav-link {
    font-size: 1.8rem;
    font-weight: 700;
    font-family: 'Inter', sans-serif;
    color: #fff;
    text-decoration: none;
    text-transform: uppercase;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.home-mobile-nav .mobile-nav-link:hover {
    transform: translateX(-5px);
    opacity: 0.7;
}

/* Search Overlay */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(26, 26, 26, 0.98);
    z-index: 5000;
    /* Higher than header and mobile menu */
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    backdrop-filter: blur(10px);
}

.search-overlay.active {
    opacity: 1;
    visibility: visible;
}

.search-overlay-content {
    width: 90%;
    max-width: 800px;
    transform: scale(0.8) translateY(-20px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.search-overlay.active .search-overlay-content {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.search-overlay-form {
    display: flex;
    align-items: center;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
    padding-bottom: 10px;
    gap: 10px;
    /* Space between input and button */
}

.search-overlay-input {
    flex: 1;
    background: none;
    border: none;
    color: white;
    font-size: 2.5rem;
    /* Reduced from 3rem */
    font-weight: 700;
    font-family: 'Inter', sans-serif;
    outline: none;
    padding: 0;
    width: 0;
    /* Allow flex to take over */
    min-width: 0;
}

.search-overlay-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.search-overlay-submit {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
    transition: color 0.3s ease;
    margin-left: 20px;
}

.search-overlay-submit:hover {
    color: #aaa;
}

.close-search {
    position: absolute;
    top: 32px;
    /* Align with topbar padding/hamburger */
    right: 4rem;
    /* Align with main-wrapper side padding */
    font-size: 3rem;
    color: white;
    background: none;
    border: none;
    cursor: pointer;
    line-height: 1;
    transition: transform 0.3s ease;
}

.close-search:hover {
    transform: rotate(90deg);
}

.search-title {
    color: white;
    font-size: 4rem;
    /* Reduced from 5rem */
    font-weight: 900;
    font-family: 'Inter', sans-serif;
    letter-spacing: -2px;
    margin-bottom: 1.5rem;
    opacity: 0.15;
    text-transform: uppercase;
}

/* Live Search Results Styles */
.live-search-results {
    margin-top: 2rem;
    max-height: 60vh;
    overflow-y: auto;
    padding-right: 10px;
}

.live-search-results::-webkit-scrollbar {
    width: 6px;
}

.live-search-results::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

.live-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    margin-bottom: 0.8rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.live-result-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(10px);
    border-color: rgba(255, 255, 255, 0.2);
}

.result-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.result-title {
    color: white;
    font-size: 1.2rem;
    font-weight: 700;
}

.result-desc {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

.result-badge {
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.badge-car {
    background: #e74c3c;
    color: white;
}

.badge-review {
    background: #3498db;
    color: white;
}

.badge-platform {
    background: #9b59b6;
    color: white;
}

.badge-engine {
    background: #f1c40f;
    color: black;
}

/* Search responsive tweaks */
@media (max-width: 768px) {
    .search-title {
        font-size: 2.5rem;
    }

    .search-overlay-input {
        font-size: 1.5rem;
    }

    .search-overlay-submit {
        font-size: 1.1rem;
        margin-left: 10px;
    }

    .search-overlay-form {
        padding-bottom: 5px;
    }

    .close-search {
        top: 1rem;
        /* Adjust for mobile topbar */
        right: 1.5rem;
        /* Adjust for mobile side padding */
        font-size: 2.5rem;
    }
}

.search-suggestions {
    margin-top: 3rem;
}

.suggestions-label {
    display: block;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
}

.suggestion-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.suggestion-pill {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.suggestion-pill:hover {
    background: white;
    color: black;
    transform: translateY(-3px);
}

/* Trending Tags */
.home-trending {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.8rem;
    /* Reduced from 2rem */
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
}


.home-trending::-webkit-scrollbar {
    display: none;
}

.trend-label {
    font-weight: 900;
    font-size: 1.2rem;
    margin-right: 0.5rem;
    color: var(--text-main);
    flex-shrink: 0;
}


.trend-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: nowrap;
}

.tag-pill {
    background: var(--card-bg);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-main);
    text-decoration: none;
    transition: all 0.2s ease;
    flex-shrink: 0;
    white-space: nowrap;
}

html.dark-mode .tag-pill,
body.dark-mode .tag-pill {
    background: #252525;
}



.tag-pill:hover {
    background: #1a1a1a;
    color: #fff;
    transform: translateY(-2px);
}

/* Categories Slider */
.home-categories-slider {
    margin-bottom: 1.5rem;
    position: relative;
    /*overflow: hidden;  Re-added to prevent horizontal overflow */
    padding: 0 0px;
    /* Space for buttons inside the overflow hidden area */
}


.slider-clip {
    overflow: hidden;
    width: 100%;
}


.home-categories-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    gap: 1.5rem;
    padding: 0 0.2rem 0 0.2rem;
    /* padding-bottom removed */
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}


.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--glass);
    border: 1px solid var(--border);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 100;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.slider-nav:hover {
    background: var(--accent);
    color: #fff;
    transform: translateY(-50%) scale(1.1);
}

.slider-nav.prev {
    left: -20px;
}

.slider-nav.next {
    right: -20px;
}



@media (max-width: 768px) {
    .slider-nav {
        display: none;
    }
}

.cat-card {
    min-width: calc(33.33% - 1.5rem);
    /* Proportional width on desktop */
    scroll-snap-align: start;
    flex-shrink: 0;
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    height: 240px;
    border: 1px solid var(--border);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (max-width: 1024px) {
    .cat-card {
        min-width: 60%;
    }
}

@media (max-width: 768px) {
    .cat-card {
        min-width: 85%;
    }

    .home-categories-slider {
        padding: 0;
        /* No buttons on mobile, so no extra padding needed */
    }
}





/* Popular Brands */
.home-popular-brands {
    margin-bottom: 2rem;
    text-align: left;
    /* Aligned to left */
}


.home-popular-brands .section-title {
    font-size: 1.3rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    color: var(--text-main);
    text-transform: uppercase;
    position: relative;
    display: inline-block;
    letter-spacing: 1px;
}

.home-popular-brands .section-title::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    /* Aligned to left */
    width: 0;
    height: 3px;
    background: var(--accent);
    transition: width 0.3s ease;
}


.home-popular-brands:hover .section-title::after {
    width: 40px;
}


.brands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 0.8rem;
    max-width: 100%;
}

.brand-square.all-brands {
    order: 999;
    /* Always show the ALL button at the very end */
}


@media (max-width: 1024px) {
    .brands-grid {
        grid-template-columns: repeat(6, 1fr);
    }
}

@media (max-width: 768px) {
    .brands-grid {
        grid-template-columns: repeat(6, 1fr);
        /* 2 rows of 6 = 12 items */
    }
}


.brand-square {
    flex: 1;
    /* Force them to fill the row equally */
    min-width: 0;
    display: flex;
    aspect-ratio: 1/1;
    background: var(--card-bg);
    border-radius: 12px;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid var(--border);
    padding: 0.8rem;
}


html.dark-mode .brand-square,
body.dark-mode .brand-square {
    background: #323235;
}

html.dark-mode .brand-logo,
body.dark-mode .brand-logo {
    filter: invert(1) brightness(2.5) contrast(0.5) opacity(0.85);
}

html.dark-mode .brand-square:hover .brand-logo,
body.dark-mode .brand-square:hover .brand-logo {
    filter: invert(1) brightness(3) contrast(1) opacity(1);
}


.brand-square.all-brands {
    display: flex !important;
    background: var(--accent);
    color: var(--header-bg);
    order: 99;
}

html.dark-mode .brand-square.all-brands,
body.dark-mode .brand-square.all-brands {
    background: #f5f4ef;
    color: #28282B;
}

html.dark-mode .brand-square.all-brands .all-text,
html.dark-mode .brand-square.all-brands .all-arrow,
body.dark-mode .brand-square.all-brands .all-text,
body.dark-mode .brand-square.all-brands .all-arrow {
    color: #28282B;
}





.brand-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: grayscale(0) opacity(1);
    transition: all 0.3s ease;
}

.brand-square:hover .brand-logo {
    filter: grayscale(1) opacity(0.6);
    transform: scale(1.1);
}


.brand-square:hover {
    background: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.brand-square.all-brands:hover {
    background: #000;
}

.all-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    color: white;
}

.all-text {
    font-weight: 900;
    font-size: 0.85rem;
    letter-spacing: 1px;
}

.all-arrow {
    width: 18px;
    height: 18px;
    transition: transform 0.3s ease;
}

/* Resolution Fitting Logic - Ensure exactly ONE row */

/* 1. Large Screen: 10 items */
/* 1. Large Screen: 12 items */
@media (min-width: 1200px) {
    .brands-grid {
        grid-template-columns: repeat(12, 1fr);
    }

    .brand-square:nth-child(-n+12) {
        display: flex;
    }
}

/* 2. Standard Desktop: 10 items */
@media (max-width: 1199px) and (min-width: 992px) {
    .brands-grid {
        grid-template-columns: repeat(10, 1fr);
    }

    .brand-square:nth-child(-n+10) {
        display: flex;
    }
}

/* 3. Tablet: 8 items */
@media (max-width: 991px) and (min-width: 769px) {
    .brands-grid {
        grid-template-columns: repeat(8, 1fr);
    }

    .brand-square:nth-child(-n+8) {
        display: flex;
    }
}

/* 4. Mobile: 5 items for a tighter look */
@media (max-width: 768px) {
    .brands-grid {
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        flex-wrap: wrap;
        /* Allow wrap for grid effect */
        gap: 0.5rem;
    }

    /* Keep exactly 10 items on mobile (9 brands + 1 all-brands) */
    .brand-square:nth-child(n+10) {
        display: none !important;
    }

    .brand-square.all-brands {
        display: flex !important;
        /* Ensure ALL is visible */
        order: 10;
    }

    .brand-square {
        flex: none;
        /* Disable PC fill logic on mobile */
        padding: 0.5rem;
        display: flex;
    }
}





/* Background watermark text on cards */


/* Background watermark text on cards */
.cat-bg-watermark {
    position: absolute;
    top: 1.5rem;
    /* Push to top inside card */
    left: 1.5rem;
    /* Left aligned */
    font-size: 4rem;
    /* Readbale font size */
    line-height: 1;
    font-family: 'Inter', sans-serif;
    font-weight: 900;
    color: rgba(220, 225, 235, 0.6);
    /* Slightly more visible if needed */
    white-space: nowrap;
    z-index: 1;
    /* Below the image */
    pointer-events: none;
    user-select: none;
}

/* Add a pseudo-element for the shadow effect instead of moving the whole card */
.cat-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    box-shadow: 0 0 0 rgba(0, 0, 0, 0);
    transition: box-shadow 0.4s ease;
    z-index: 5;
    pointer-events: none;
}

.cat-card:hover::before {
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.05), inset 0 0 0 4px rgba(255, 255, 255, 0.4), 0 10px 30px rgba(0, 0, 0, 0.15);
}

.cat-card img {
    /* The image itself is now positioned to allow the watermark strictly behind it */
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 2;
    /* Content image sits above the watermark */
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.4s ease;
}

.cat-card:hover img {
    transform: scale(1.05);
    /* Image zoom remains */
    filter: brightness(1.1);
}

.cat-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60%;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    transition: height 0.3s ease, background 0.3s ease;
    z-index: 10;
}

.cat-card:hover .cat-overlay {
    height: 70%;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
}

.cat-text-content {
    position: absolute;
    bottom: 1.5rem;
    left: 1.5rem;
    right: 1.5rem;
    z-index: 15;
    transition: transform 0.3s ease;
}

.cat-header-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.cat-arrow {
    color: white;
    opacity: 0.6;
    transform: translateX(-10px);
    transition: all 0.4s ease;
}

.cat-card:hover .cat-arrow {
    opacity: 1;
    transform: translateX(0);
}

.cat-text-content h3 {
    color: white;
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}


.cat-desc {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.85rem;
    margin: 0.2rem 0 0 0;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.cat-card:hover .cat-text-content h3 {
    letter-spacing: 1px;
}

.cat-card:hover .cat-desc {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Rules for Homepage */
body.home .mobile-header {
    display: none !important;
}

@media (max-width: 1024px) {
    .home-topbar {
        margin: 0 auto 1rem auto;
        padding: 1rem 1.5rem;
    }
}


@media (max-width: 850px) {
    .topbar-nav {
        display: none;
    }

    .home-hamburger {
        display: flex;
    }
}

@media (max-width: 768px) {
    .home-lists-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .topbar-actions {
        width: auto;
    }

    .topbar-actions .search-btn {
        padding: 0.6rem;
        font-size: 0;
        width: 44px;
        height: 44px;
        border-radius: 50%;
    }

    .search-btn-text {
        display: none;
    }

    .search-btn-icon {
        display: block;
        color: var(--accent);
    }

    .home-topbar {
        margin-bottom: 1rem;
    }

    .home-trending {
        justify-content: flex-start;
        padding-bottom: 0.5rem;
        /* give space for scrolling */
    }

    .search-overlay-input {
        font-size: 1.5rem;
    }

    .topbar-logo {
        font-size: 1.6rem;
    }
}

/* Lists Grid */
.home-lists-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}

@media (max-width: 768px) {
    .home-lists-grid {
        grid-template-columns: 1fr;
    }

    .home-categories {
        grid-template-columns: 1fr;
    }
}

.list-col-title {
    font-size: 1.3rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    color: var(--text-main);
    text-transform: uppercase;
    position: relative;
    display: inline-block;
}


.list-col-title::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--accent);
    transition: width 0.3s ease;
}

.list-column:hover .list-col-title::after {
    width: 40px;
}

.list-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.home-list-item {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    height: 70px;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}

html.dark-mode .home-list-item,
body.dark-mode .home-list-item {
    background: #1a1a1a;
    border: 1px solid rgba(255, 255, 255, 0.05);
}



.home-list-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background: #1a1a1a;
    transform: scaleY(0);
    transition: transform 0.2s ease;
}

.home-list-item:hover:not(.empty) {
    background: var(--accent);
    color: #1a1a1a !important;
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.home-list-item:hover .list-item-info .model,
.home-list-item:hover .list-item-info .brand {
    color: #1a1a1a !important;
}



.home-list-item:hover:not(.empty)::before {
    transform: scaleY(1);
}

.home-list-item.empty {
    background: #e6e5dd;
    opacity: 0.5;
    cursor: default;
}

.list-item-img {
    width: 60px;
    height: 40px;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
    flex-shrink: 0;
}

.list-item-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.home-list-item:hover .list-item-img img {
    transform: scale(1.1);
}

.list-item-info {
    display: flex;
    flex-direction: column;
}

.list-item-info .brand {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--text-muted);
    transition: color 0.2s ease;
}

.home-list-item:hover .list-item-info .brand {
    color: var(--accent);
}

.list-item-info .model {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--text-main);
}


/* Top Reviews */
.home-reviews {
    margin-bottom: 4rem;
}

.reviews-section-title {
    font-size: 1.3rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    color: var(--accent);
}


.reviews-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

@media (max-width: 900px) {
    .reviews-grid {
        grid-template-columns: 1fr;
    }
}

.review-card {
    text-decoration: none;
    color: inherit;
    display: block;
    border-radius: 16px;
    padding-bottom: 1rem;
    transition: transform 0.3s ease;
}

.review-card:hover {
    transform: translateY(-5px);
}

.review-card.empty {
    visibility: hidden;
}

.review-img {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    position: relative;
}

.review-img::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    transition: background 0.3s ease;
}

.review-card:hover .review-img::after {
    background: rgba(0, 0, 0, 0.2);
}

.play-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
    background: rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.review-card:hover .play-overlay {
    background: rgba(0,0,0,0.4);
}

.play-overlay svg {
    filter: drop-shadow(0 4px 10px rgba(0,0,0,0.3));
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.review-card:hover .play-overlay svg {
    transform: scale(1.2);
}

.review-img.cat-card {
    min-width: calc(33.33% - 1rem);
    height: 220px;
    /* Force height for visibility */
    background: #232326;
    border-radius: 24px;
    position: relative;
    overflow: hidden;
    scroll-snap-align: start;
    flex-shrink: 0;
    z-index: 50;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.cat-card img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.review-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.review-card:hover .review-img img {
    transform: scale(1.05);
}

.review-info h3 {
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0;
    color: var(--text-main);
    transition: color 0.2s ease;
}


.review-card:hover .review-info h3 {
    color: var(--accent);
}

html.dark-mode .review-info h3,
body.dark-mode .review-info h3 {
    color: #fff;
}

/* Brands Header Layout */
.brands-header-flex {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 1rem;
    padding-top: 1rem;
    gap: 2rem;
}

.brands-title-area .page-title {
    font-size: 2.5rem;
    font-weight: 900;
    font-family: 'Inter', sans-serif;
    letter-spacing: -1px;
    margin: 0;
    line-height: 1;
}

.brands-subtitle {
    margin-top: 1rem;
    font-weight: 700;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    opacity: 0.7;
}

.brands-page-desc {
    margin-bottom: 2.5rem;
    color: var(--text-muted);
    font-size: 1.1rem;
    line-height: 1.6;
    max-width: 800px;
    font-weight: 500;
}

/* Custom Dropdowns */
.brands-filter-area {
    display: flex;
    align-items: center;
}

.custom-filter-form {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.custom-dropdown {
    position: relative;
    min-width: 150px;
}

.dropdown-trigger {
    background: var(--card-bg);
    padding: 0.8rem 1.2rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-main);
    transition: all 0.3s ease;
    border: 1px solid var(--border);
}

.dropdown-trigger:hover {
    background: var(--accent);
    color: var(--header-bg);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}


.dropdown-trigger svg {
    opacity: 0.4;
    transition: transform 0.3s ease;
}

.custom-dropdown.active .dropdown-trigger svg {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 220px;
    background: var(--header-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow-soft);
    padding: 0.8rem;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.custom-dropdown.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    padding: 0.8rem 1.2rem;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background: var(--accent);
    color: var(--header-bg);
}


/* Grouped Sections */
.brands-group-section {
    margin-bottom: 5rem;
}

.group-section-title {
    font-size: 1.2rem;
    font-weight: 900;
    color: var(--accent);
    letter-spacing: 2px;
    margin-bottom: 2rem;
    padding-bottom: 0.8rem;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
}


.brands-directory-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

/* Updated Brand Directory Card with less padding */
.brand-directory-card {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 1.2rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    text-decoration: none;
    color: inherit;
    border: 1px solid var(--border);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
    min-height: 80px;
    /* Ensure consistency */
}

html.dark-mode .brand-directory-card,
body.dark-mode .brand-directory-card {
    background: var(--card-bg);
}


.brand-directory-card svg {
    margin-left: auto;
    /* Push arrow to the exact same spot regardless of text */
    flex-shrink: 0;
    opacity: 0.4;
    transition: all 0.3s ease;
}

.brand-directory-card:hover svg {
    transform: translateX(5px);
    opacity: 1;
    color: var(--accent);
}




.brand-card-logo {
    width: 50px;
    /* Bit smaller */
    height: 50px;
    background: white;
    border-radius: 12px;
    padding: 8px;
    flex-shrink: 0;
}

.brand-card-name {
    font-size: 1.2rem;
    /* Bit smaller */
}

/* Brands Page Layout Cleanup */
.brands-group-section {
    margin-bottom: 0rem;
}

.group-title-container {
    position: relative;
    padding: 2rem 0rem 0rem 0rem;
    margin-bottom: 1rem;
}

.group-section-title {
    font-size: 1.4rem;
    font-weight: 800;
    margin-bottom: 0;
    color: var(--text-main);
    letter-spacing: 0.5px;
    position: relative;
    z-index: 2;
}

.group-section-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    max-width: 800px;
    line-height: 1.5;
}

/* Flag Effect - Only in Title Area */
.flag-bg-overlay {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background-size: auto 50%;
    background-position: right center;
    background-repeat: no-repeat;
    opacity: 0.2;
    /* Slightly increased for title area visibility */
    z-index: 1;
    pointer-events: none;
    mask-image: linear-gradient(to right, transparent 0%, black 100%);
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 100%);
}

.group-section-content {
    position: relative;
    z-index: 2;
}

.brands-group-section.has-flag-effect .group-section-content {
    padding: 0;
}

/* Quick Versus Widget - Redesigned */
.vs-widget {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 32px;
    gap: 4rem; /* Explicit horizontal gap */
    position: relative;
    overflow: hidden;
    min-height: 320px;
}

.vs-car-side {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1.5rem;
    z-index: 2;
    transition: all 0.4s ease;
    width: 35%; /* Fixed width for better horizontal alignment */
}

.vs-widget:hover .vs-car-side {
    filter: blur(2px);
    opacity: 0.5;
    transform: scale(0.95);
}

.vs-widget:hover .vs-car-side:hover {
    filter: blur(0);
    opacity: 1;
    transform: scale(1.05);
}

.vs-car-image {
    width: 280px;
    height: 160px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vs-car-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 15px 30px rgba(0,0,0,0.2));
}

.vs-car-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.vs-brand {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--accent);
    letter-spacing: 2px;
}

.vs-model {
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--text-main);
    letter-spacing: -1px;
}

.vs-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 120px;
    flex-shrink: 0;
    position: relative;
    z-index: 5;
}

.vs-circle {
    width: 70px;
    height: 70px;
    background: #000;
    color: #fff;
    border: 4px solid var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 1.4rem;
    box-shadow: 0 10px 40px rgba(0,0,0,0.4);
    font-style: italic;
}

.vs-line {
    position: absolute;
    width: 1px;
    height: 300px;
    background: linear-gradient(transparent, var(--border), transparent);
    z-index: 1;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}

.vs-compare-btn {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translate(-50%, 50px);
    background: var(--accent);
    color: #1a1a1a;
    padding: 1rem 3rem;
    border-radius: 50px;
    font-weight: 900;
    font-size: 0.9rem;
    text-decoration: none;
    letter-spacing: 1px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 20;
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
}

.vs-widget:hover .vs-compare-btn {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -40px);
}

/* Newsletter Section - RE-ADDED */
.home-newsletter {
    background: var(--accent);
    border: none;
    border-radius: 32px;
    padding: 3rem;
    color: #1a1a1a;
    position: relative;
    overflow: hidden;
}

.newsletter-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
    position: relative;
    z-index: 2;
}

.newsletter-text h2 {
    margin: 0;
    font-size: 2rem;
    font-weight: 900;
    letter-spacing: -1px;
    line-height: 1.2;
}

.newsletter-text p {
    margin: 0.5rem 0 0 0;
    font-size: 1rem;
    font-weight: 500;
    opacity: 0.8;
}

.newsletter-form {
    display: flex;
    gap: 0.8rem;
    flex: 1.2;
    max-width: 600px;
}

.newsletter-form input {
    flex: 1;
    background: #fff;
    border: 2px solid transparent;
    padding: 1.2rem 1.5rem;
    border-radius: 16px;
    outline: none;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
}

.newsletter-form input:focus {
    border-color: #000;
}

.newsletter-form button {
    background: #000;
    color: #fff;
    border: none;
    padding: 0 3rem;
    border-radius: 16px;
    font-weight: 900;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 1px;
}

.newsletter-form button:hover {
    background: #222;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

@media (max-width: 1024px) {
    .home-newsletter {
        padding: 2rem 1.5rem;
    }
    .newsletter-content {
        flex-direction: column;
        text-align: center;
        gap: 2rem;
    }
    .newsletter-form {
        flex-direction: column;
        width: 100%;
        max-width: 100%;
        gap: 1rem;
    }
    .newsletter-form button {
        padding: 1.2rem;
        width: 100%;
    }
}

@media (max-width: 1024px) {
    .vs-car-image {
        width: 200px;
        height: 120px;
    }
    .vs-model {
        font-size: 1.4rem;
    }
}

@media (max-width: 900px) {
    .vs-widget {
        gap: 1rem;
        padding: 2rem 1rem 5rem 1rem;
        min-height: auto;
    }
    .vs-car-image {
        width: 140px;
        height: 80px;
    }
    .vs-model {
        font-size: 1.1rem;
    }
    .vs-divider {
        width: 60px;
    }
    .vs-circle {
        width: 50px;
        height: 50px;
        font-size: 1rem;
    }
    .vs-line {
        height: 200px;
    }
}

@media (max-width: 768px) {
    .brands-header-flex {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }

    .brands-title-area .page-title {
        font-size: 2rem;
    }

    .custom-filter-form {
        flex-wrap: wrap;
    }

    .custom-dropdown {
        flex: 1;
        min-width: calc(50% - 1rem);
    }
}

/* Legendary Engine Section */
.home-legendary-engine {
    margin-bottom: 3rem;
}

.legendary-engine-card {
    display: flex;
    gap: 1.5rem;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 20px;
    padding: 1.2rem;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.legendary-engine-card:hover {
    background: rgba(255,255,255,0.06);
    border-color: rgba(255,255,255,0.1);
}

.engine-image {
    flex: 0 0 140px;
    border-radius: 12px;
    overflow: hidden;
    height: 140px;
}

.engine-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.legendary-engine-card:hover .engine-image img {
    transform: scale(1.05);
}

.engine-details {
    flex: 1;
}

.engine-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.engine-header h3 {
    font-size: 1.3rem;
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    color: #fff;
    margin: 0;
    letter-spacing: -0.5px;
}

.engine-badge {
    background: var(--accent);
    color: #000;
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    font-weight: 900;
    font-size: 0.75rem;
}

.engine-desc {
    color: rgba(255,255,255,0.7);
    font-size: 0.85rem;
    line-height: 1.4;
    margin-bottom: 1rem;
}

.engine-specs {
    display: flex;
    gap: 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 1rem;
}

.spec-item {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.spec-label {
    font-size: 0.65rem;
    color: rgba(255,255,255,0.4);
    text-transform: uppercase;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.spec-value {
    font-size: 0.9rem;
    color: #fff;
    font-weight: 700;
}

/* Light Mode Overrides for Legendary Engine */
html:not(.dark-mode) body:not(.dark-mode) .legendary-engine-card {
    background: #fff;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-soft);
}

html:not(.dark-mode) body:not(.dark-mode) .legendary-engine-card:hover {
    box-shadow: 0 15px 35px rgba(0,0,0,0.06);
    border-color: var(--accent);
}

html:not(.dark-mode) body:not(.dark-mode) .engine-header h3 {
    color: var(--text-main);
}

html:not(.dark-mode) body:not(.dark-mode) .engine-desc {
    color: var(--text-muted);
}

html:not(.dark-mode) body:not(.dark-mode) .engine-specs {
    border-color: rgba(0,0,0,0.1);
}

html:not(.dark-mode) body:not(.dark-mode) .spec-label {
    color: rgba(0,0,0,0.4);
}

html:not(.dark-mode) body:not(.dark-mode) .spec-value {
    color: var(--text-main);
}

@media (max-width: 768px) {
    .legendary-engine-card {
        flex-direction: column;
        gap: 1.5rem;
        align-items: stretch;
    }
    .engine-image {
        height: 160px;
        width: 100%;
        flex: auto;
    }
    .engine-specs {
        flex-wrap: wrap;
        gap: 1rem;
        justify-content: space-between;
    }
}