/* CSS Variables */
:root {
    --primary-color: #3b82f6;
    --primary-dark: #1d4ed8;
    --primary-light: #60a5fa;
    --secondary-color: #10b981;
    --accent-color: #f59e0b;
    --text-primary: #1f2937;
    --text-secondary: #4b5563;
    --text-muted: #6b7280;
    --bg-primary: #ffffff;
    --bg-secondary: #f3f4f6;
    --bg-tertiary: #e5e7eb;
    --border-color: #d1d5db;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --transition-fast: 150ms ease;
    --transition-normal: 300ms ease;
}

/* Reset & Base Styles */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

ul {
    list-style: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

select {
    font-family: inherit;
}

/* Container */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 800;
}

.logo-icon {
    font-size: 1.75rem;
}

.logo-text .highlight {
    color: var(--primary-color);
}

.nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    font-weight: 500;
    color: var(--text-secondary);
    padding: 0.5rem 0;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width var(--transition-normal);
}

.nav-link:hover {
    color: var(--primary-color);
}

.nav-link:hover::after {
    width: 100%;
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 0.5rem;
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition-fast);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-tertiary);
    border-color: var(--text-muted);
}

.btn-success {
    background: var(--secondary-color);
    color: white;
}

.btn-success:hover {
    background: #059669;
    transform: translateY(-2px);
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

/* Hero Section */
.hero {
    padding: 8rem 0 4rem;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 50%, #f0fdf4 100%);
    min-height: 90vh;
    display: flex;
    align-items: center;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 500px;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.hero-stats {
    display: flex;
    gap: 3rem;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-color);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-car-graphic {
    width: 100%;
    max-width: 500px;
    animation: float 3s ease-in-out infinite;
}

.suv-illustration {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.15));
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

/* Section Titles */
.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 0.75rem;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    text-align: center;
    max-width: 600px;
    margin: 0 auto 2.5rem;
}

/* Categories Section */
.categories {
    padding: 4rem 0 2rem;
    background: var(--bg-primary);
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.filter-btn {
    padding: 0.625rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    border: 1px solid transparent;
    transition: all var(--transition-fast);
}

.filter-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.filter-btn.active {
    background: var(--primary-color);
    color: white;
}

.view-toggle {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}

.view-btn {
    padding: 0.625rem;
    border-radius: var(--radius-md);
    background: var(--bg-secondary);
    color: var(--text-muted);
    transition: all var(--transition-fast);
}

.view-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.view-btn.active {
    background: var(--primary-color);
    color: white;
}

/* Products Grid */
.products-section {
    padding: 2rem 0 4rem;
    background: var(--bg-secondary);
}

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

/* Product Card */
.product-card {
    background: var(--bg-primary);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-normal);
    position: relative;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.product-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    background: var(--accent-color);
    color: white;
    z-index: 10;
}

.product-badge.hybrid {
    background: var(--secondary-color);
}

.product-badge.luxury {
    background: #8b5cf6;
}

.product-image {
    position: relative;
    height: 200px;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-image svg {
    width: 80%;
    height: auto;
    transition: transform var(--transition-normal);
}

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

.product-content {
    padding: 1.5rem;
}

.product-brand {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.product-name {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.product-price {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.product-price strong {
    font-size: 1.25rem;
    color: var(--text-primary);
}

.product-specs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    padding: 1rem 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1rem;
}

.spec-item {
    text-align: center;
}

.spec-value {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

.spec-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.stars {
    color: var(--accent-color);
    letter-spacing: 2px;
}

.rating-value {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.product-actions {
    display: flex;
    gap: 0.75rem;
}

.product-actions .btn {
    flex: 1;
}

/* Products Table */
.products-table-container {
    overflow-x: auto;
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
}

.products-table {
    width: 100%;
    border-collapse: collapse;
}

.products-table th,
.products-table td {
    padding: 1rem 1.25rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.products-table th {
    background: var(--bg-secondary);
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--text-secondary);
}

.products-table tbody tr:hover {
    background: var(--bg-secondary);
}

.products-table .stars {
    font-size: 0.875rem;
}

.hidden {
    display: none !important;
}

/* Compare Section */
.compare-section {
    padding: 5rem 0;
    background: var(--bg-primary);
}

.compare-selectors {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.compare-slot {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.compare-select {
    width: 100%;
    padding: 0.875rem 1rem;
    font-size: 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-primary);
    cursor: pointer;
    transition: border-color var(--transition-fast);
}

.compare-select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.compare-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    min-height: 300px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    border: 2px dashed var(--border-color);
    transition: all var(--transition-normal);
}

.compare-card.filled {
    border: 2px solid var(--primary-color);
    background: var(--bg-primary);
    box-shadow: var(--shadow-md);
}

.placeholder-text {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.compare-card-content {
    width: 100%;
}

.compare-card-content h4 {
    font-size: 1.125rem;
    margin-bottom: 0.25rem;
}

.compare-card-content .brand {
    font-size: 0.75rem;
    color: var(--primary-color);
    text-transform: uppercase;
    font-weight: 600;
    margin-bottom: 1rem;
}

.compare-card-content .price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.compare-card-image {
    height: 120px;
    margin-bottom: 1rem;
}

.compare-card-image svg {
    width: 100%;
    height: 100%;
}

/* Comparison Table */
.comparison-table-wrapper {
    margin-top: 3rem;
    overflow-x: auto;
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
}

.comparison-table th,
.comparison-table td {
    padding: 1rem 1.5rem;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.comparison-table th {
    background: var(--primary-color);
    color: white;
    font-weight: 600;
}

.comparison-table th:first-child {
    text-align: left;
    background: var(--primary-dark);
}

.comparison-table td:first-child {
    text-align: left;
    font-weight: 500;
    background: var(--bg-secondary);
}

.comparison-table tbody tr:hover {
    background: var(--bg-secondary);
}

.comparison-table tbody tr:hover td:first-child {
    background: var(--bg-tertiary);
}

/* Quiz Section */
.quiz-section {
    padding: 5rem 0;
    background: linear-gradient(135deg, #eff6ff 0%, #f0fdf4 100%);
}

.quiz-container {
    max-width: 700px;
    margin: 0 auto;
    background: var(--bg-primary);
    border-radius: var(--radius-xl);
    padding: 3rem;
    box-shadow: var(--shadow-xl);
}

.quiz-container .section-title {
    font-size: 2rem;
}

.quiz-progress {
    margin-bottom: 2rem;
}

.progress-bar {
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 4px;
    transition: width var(--transition-normal);
    width: 20%;
}

.progress-text {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.quiz-content {
    margin-bottom: 2rem;
}

.quiz-question {
    margin-bottom: 1.5rem;
}

.quiz-question h3 {
    font-size: 1.25rem;
    margin-bottom: 1.25rem;
    color: var(--text-primary);
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.quiz-option {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: var(--bg-secondary);
    border: 2px solid transparent;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.quiz-option:hover {
    background: var(--bg-tertiary);
    border-color: var(--border-color);
}

.quiz-option.selected {
    background: #eff6ff;
    border-color: var(--primary-color);
}

.quiz-option input {
    width: 20px;
    height: 20px;
    accent-color: var(--primary-color);
}

.quiz-option span {
    font-size: 1rem;
    color: var(--text-primary);
}

.quiz-navigation {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

.quiz-navigation .btn {
    min-width: 120px;
}

.quiz-navigation .btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Quiz Results */
.quiz-results {
    text-align: center;
}

.quiz-results h3 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    color: var(--secondary-color);
}

.result-cards {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.result-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    text-align: left;
    border: 2px solid var(--border-color);
    transition: all var(--transition-normal);
}

.result-card:first-child {
    border-color: var(--accent-color);
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
}

.result-card-rank {
    font-size: 2rem;
    font-weight: 800;
    color: var(--accent-color);
    min-width: 50px;
}

.result-card:first-child .result-card-rank {
    color: var(--accent-color);
}

.result-card-info {
    flex: 1;
}

.result-card-info h4 {
    font-size: 1.125rem;
    margin-bottom: 0.25rem;
}

.result-card-info p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.match-score {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--secondary-color);
}

.result-card .btn {
    white-space: nowrap;
}

/* SEO Content Section */
.seo-content {
    padding: 5rem 0;
    background: var(--bg-secondary);
}

.seo-article {
    max-width: 900px;
    margin: 0 auto;
    background: var(--bg-primary);
    padding: 3rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
}

.seo-article h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.seo-article h3 {
    font-size: 1.375rem;
    margin: 2rem 0 1rem;
    color: var(--text-primary);
}

.seo-article p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

.seo-article ul {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.seo-article li {
    margin-bottom: 0.75rem;
    color: var(--text-secondary);
    line-height: 1.7;
    position: relative;
    padding-left: 1rem;
}

.seo-article li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.seo-article strong {
    color: var(--text-primary);
}

/* Footer */
.footer {
    background: var(--text-primary);
    color: var(--bg-tertiary);
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand .logo {
    margin-bottom: 1rem;
}

.footer-brand .logo-text {
    color: white;
}

.footer-brand p {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.7;
}

.footer-links h4 {
    font-size: 1rem;
    font-weight: 600;
    color: white;
    margin-bottom: 1.25rem;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    font-size: 0.9rem;
    color: var(--text-muted);
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--primary-light);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--text-secondary);
    text-align: center;
}

.footer-bottom p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.affiliate-disclosure {
    font-size: 0.75rem !important;
    opacity: 0.7;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-content h1 {
        font-size: 2.75rem;
    }

    .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-buttons {
        justify-content: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .hero-image {
        order: -1;
    }

    .hero-car-graphic {
        max-width: 400px;
    }

    .compare-selectors {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .nav {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 1rem;
        gap: 0;
        box-shadow: var(--shadow-md);
    }

    .nav.active {
        display: flex;
    }

    .nav-link {
        padding: 1rem;
        border-bottom: 1px solid var(--border-color);
    }

    .mobile-menu-btn {
        display: flex;
    }

    .hero {
        padding-top: 6rem;
        min-height: auto;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

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

    .hero-buttons {
        flex-direction: column;
    }

    .hero-stats {
        gap: 2rem;
    }

    .stat-number {
        font-size: 1.5rem;
    }

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

    .filter-bar {
        gap: 0.5rem;
    }

    .filter-btn {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }

    .products-grid {
        grid-template-columns: 1fr;
    }

    .quiz-container {
        padding: 1.5rem;
    }

    .quiz-container .section-title {
        font-size: 1.5rem;
    }

    .quiz-navigation {
        flex-direction: column;
    }

    .result-card {
        flex-direction: column;
        text-align: center;
    }

    .result-card-info {
        text-align: center;
    }

    .seo-article {
        padding: 1.5rem;
    }

    .seo-article h2 {
        font-size: 1.5rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .products-table th,
    .products-table td {
        padding: 0.75rem 0.5rem;
        font-size: 0.8rem;
    }

    .comparison-table th,
    .comparison-table td {
        padding: 0.75rem 0.5rem;
        font-size: 0.8rem;
    }
}

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

.product-card {
    animation: fadeIn 0.5s ease forwards;
}

.product-card:nth-child(1) { animation-delay: 0.1s; }
.product-card:nth-child(2) { animation-delay: 0.2s; }
.product-card:nth-child(3) { animation-delay: 0.3s; }
.product-card:nth-child(4) { animation-delay: 0.4s; }
.product-card:nth-child(5) { animation-delay: 0.5s; }
.product-card:nth-child(6) { animation-delay: 0.6s; }

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

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

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

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

/* Focus States for Accessibility */
a:focus,
button:focus,
select:focus,
input:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .header,
    .hero,
    .quiz-section,
    .footer {
        display: none;
    }

    .product-card {
        break-inside: avoid;
        page-break-inside: avoid;
    }
}
