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

:root {
    --primary: #2d8a39;
    --primary-dark: #1e6b28;
    --primary-light: #4aa858;
    --secondary: #e63946;
    --secondary-dark: #c5303c;
    --accent: #ff6b35;
    --background: #fefefe;
    --surface: #ffffff;
    --text: #1a1a2e;
    --text-light: #4a4a68;
    --text-muted: #7a7a98;
    --border: #e8e8f0;
    --shadow: rgba(0, 0, 0, 0.1);
    --shadow-lg: rgba(0, 0, 0, 0.15);
    --gradient: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    --gradient-hot: linear-gradient(135deg, var(--secondary) 0%, var(--accent) 100%);
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 20px;
    --transition: 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--background);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

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

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.3;
}

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

a:hover {
    color: var(--primary-dark);
}

.hidden {
    display: none !important;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    font-size: 1rem;
    font-weight: 500;
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(45, 138, 57, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(45, 138, 57, 0.4);
    color: white;
}

.btn-secondary {
    background: white;
    color: var(--primary);
    border: 2px solid var(--primary);
}

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

.btn-amazon {
    background: #ff9900;
    color: #111;
    font-weight: 600;
}

.btn-amazon:hover {
    background: #e8890a;
    color: #111;
    transform: translateY(-2px);
}

.btn-sm {
    padding: 10px 20px;
    font-size: 0.9rem;
}

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

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

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
}

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

.nav {
    display: flex;
    gap: 32px;
}

.nav a {
    color: var(--text);
    font-weight: 500;
    position: relative;
}

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

.nav a:hover::after {
    width: 100%;
}

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

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background: var(--text);
    border-radius: 2px;
    transition: var(--transition);
}

/* Hero Section */
.hero {
    padding: 140px 0 80px;
    background: linear-gradient(135deg, #f0f9f1 0%, #e8f5e9 100%);
    text-align: center;
}

.hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    margin-bottom: 20px;
    color: var(--text);
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto 40px;
}

.hero-cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 60px;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
}

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

/* Section Styles */
.products-section,
.quiz-section,
.compare-section,
.about-section {
    padding: 80px 0;
}

.quiz-section {
    background: linear-gradient(135deg, #fff5f5 0%, #fff0ed 100%);
}

.compare-section {
    background: #f8f9fa;
}

h2 {
    font-size: 2.2rem;
    text-align: center;
    margin-bottom: 12px;
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 40px;
    font-size: 1.1rem;
}

/* Category Filter */
.category-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 30px;
}

.filter-btn {
    padding: 10px 24px;
    background: white;
    border: 2px solid var(--border);
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
}

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

/* View Toggle */
.view-toggle {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-bottom: 24px;
}

.view-btn {
    padding: 10px 14px;
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition);
    color: var(--text-muted);
}

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

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.product-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 4px 20px var(--shadow);
    transition: all var(--transition);
    position: relative;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px var(--shadow-lg);
}

.product-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #f5f5f5 0%, #ebebeb 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
}

.product-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 6px 14px;
    background: var(--gradient-hot);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 50px;
    text-transform: uppercase;
}

.product-content {
    padding: 20px;
}

.product-category {
    font-size: 0.8rem;
    color: var(--primary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.product-title {
    font-size: 1.15rem;
    margin-bottom: 8px;
    color: var(--text);
}

.product-description {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 16px;
    line-height: 1.5;
}

.product-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #ffc107;
    font-size: 0.9rem;
}

.product-rating span {
    color: var(--text);
    font-weight: 500;
}

.heat-level {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.85rem;
}

.heat-icon {
    color: var(--secondary);
}

.product-price {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.product-actions {
    display: flex;
    gap: 10px;
}

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

.compare-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-light);
    cursor: pointer;
    padding: 8px 0;
}

.compare-checkbox input {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

/* Products Table */
.products-table-wrapper {
    overflow-x: auto;
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 20px var(--shadow);
}

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

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

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

.products-table tr:hover {
    background: #f8f9fa;
}

.products-table .product-title {
    font-size: 1rem;
    margin-bottom: 0;
}

/* Quiz Section */
.quiz-container {
    max-width: 700px;
    margin: 0 auto;
    background: white;
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: 0 4px 30px var(--shadow);
}

.quiz-progress {
    margin-bottom: 30px;
}

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

.progress-fill {
    height: 100%;
    background: var(--gradient);
    width: 25%;
    transition: width 0.5s ease;
}

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

.quiz-question {
    margin-bottom: 30px;
}

.quiz-question h3 {
    font-size: 1.4rem;
    margin-bottom: 24px;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.quiz-option {
    padding: 16px 20px;
    background: #f8f9fa;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all var(--transition);
    font-size: 1rem;
    text-align: left;
}

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

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

.quiz-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
}

.quiz-result h3 {
    font-size: 1.6rem;
    margin-bottom: 24px;
    text-align: center;
    color: var(--primary);
}

.result-products {
    display: grid;
    gap: 20px;
    margin-bottom: 30px;
}

.result-card {
    display: flex;
    gap: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: var(--radius);
    align-items: center;
}

.result-card-image {
    font-size: 3rem;
    width: 80px;
    height: 80px;
    background: white;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.result-card-content h4 {
    margin-bottom: 8px;
}

.result-card-content p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 12px;
}

#retakeQuiz {
    display: block;
    margin: 0 auto;
}

/* Compare Section */
.compare-selector {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.compare-slot {
    background: white;
    padding: 20px;
    border-radius: var(--radius);
    box-shadow: 0 2px 10px var(--shadow);
}

.compare-select {
    width: 100%;
    padding: 12px 16px;
    font-size: 1rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: white;
    cursor: pointer;
    font-family: inherit;
}

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

.compare-product-preview {
    margin-top: 16px;
    text-align: center;
    min-height: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.compare-product-preview .preview-icon {
    font-size: 3rem;
    margin-bottom: 12px;
}

.compare-product-preview h4 {
    font-size: 1rem;
    margin-bottom: 8px;
}

.compare-product-preview p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.compare-table-wrapper {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 4px 20px var(--shadow);
}

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

.compare-table th,
.compare-table td {
    padding: 16px 20px;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

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

.compare-table th:first-child,
.compare-table td:first-child {
    text-align: left;
    font-weight: 500;
    background: #f8f9fa;
}

.compare-table tr:last-child td {
    border-bottom: none;
}

/* About Section */
.about-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
}

.about-text h3 {
    font-size: 1.4rem;
    margin: 32px 0 16px;
    color: var(--text);
}

.about-text h3:first-child {
    margin-top: 0;
}

.about-text p {
    color: var(--text-light);
    margin-bottom: 16px;
}

.about-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.info-card {
    background: white;
    padding: 24px;
    border-radius: var(--radius);
    box-shadow: 0 2px 15px var(--shadow);
}

.info-card h4 {
    font-size: 1.1rem;
    margin-bottom: 16px;
    color: var(--primary);
}

.info-card ul {
    list-style: none;
}

.info-card li {
    padding: 8px 0;
    color: var(--text-light);
    border-bottom: 1px solid var(--border);
    font-size: 0.95rem;
}

.info-card li:last-child {
    border-bottom: none;
}

/* Footer */
.footer {
    background: var(--text);
    color: white;
    padding: 60px 0 30px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer-brand .logo-icon {
    font-size: 2rem;
}

.footer-brand .logo-text {
    font-size: 1.5rem;
    font-weight: 700;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.7);
    max-width: 300px;
}

.footer-links h4 {
    font-size: 1.1rem;
    margin-bottom: 20px;
}

.footer-links a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    padding: 8px 0;
    transition: color var(--transition);
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

.affiliate-disclosure {
    margin-top: 12px;
    font-size: 0.8rem !important;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .about-content {
        grid-template-columns: 1fr;
    }

    .about-sidebar {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .info-card {
        flex: 1;
        min-width: 250px;
    }

    .footer-content {
        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: 20px;
        gap: 0;
        box-shadow: 0 4px 20px var(--shadow);
    }

    .nav.active {
        display: flex;
    }

    .nav a {
        padding: 16px 0;
        border-bottom: 1px solid var(--border);
    }

    .nav a::after {
        display: none;
    }

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

    .hero {
        padding: 120px 0 60px;
    }

    .hero-stats {
        gap: 30px;
    }

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

    .quiz-container {
        padding: 24px;
    }

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

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

    .footer-brand {
        align-items: center;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.8rem;
    }

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

    .hero-cta .btn {
        width: 100%;
    }

    .category-filter {
        gap: 8px;
    }

    .filter-btn {
        padding: 8px 16px;
        font-size: 0.85rem;
    }

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