/* ===== CSS Variables ===== */
:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary: #64748b;
    --accent: #f59e0b;
    --success: #10b981;
    --error: #ef4444;
    --background: #f8fafc;
    --surface: #ffffff;
    --text: #1e293b;
    --text-light: #64748b;
    --text-muted: #94a3b8;
    --border: #e2e8f0;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    --radius-sm: 6px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition: all 0.2s ease;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background-color: var(--background);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

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

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

ul {
    list-style: none;
}

/* ===== Container ===== */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== Utility Classes ===== */
.hidden {
    display: none !important;
}

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

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    color: white;
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

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

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

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

.btn-accent:hover {
    background: #d97706;
    color: white;
    transform: translateY(-1px);
}

.btn-small {
    padding: 8px 16px;
    font-size: 13px;
}

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

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

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

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

.logo-icon {
    font-size: 28px;
}

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

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

.nav-link {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-light);
    transition: var(--transition);
}

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

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

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

/* ===== Hero Section ===== */
.hero {
    padding: 80px 0;
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f4ff 100%);
}

.hero-content {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.hero h1 {
    font-size: 48px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-light);
    margin-bottom: 32px;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 48px;
}

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

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 28px;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    font-size: 14px;
    color: var(--text-light);
}

/* ===== Section Headers ===== */
.section-header {
    text-align: center;
    margin-bottom: 40px;
}

.section-header h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 12px;
}

.section-header p {
    font-size: 16px;
    color: var(--text-light);
}

/* ===== Filter Section ===== */
.filter-section {
    padding: 60px 0 20px;
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: flex-end;
    background: var(--surface);
    padding: 24px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.filter-group {
    flex: 1;
    min-width: 150px;
}

.filter-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-light);
    margin-bottom: 6px;
}

.filter-select {
    width: 100%;
    padding: 10px 14px;
    font-size: 14px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    cursor: pointer;
    transition: var(--transition);
}

.filter-select:hover {
    border-color: var(--primary-light);
}

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

.view-toggle {
    display: flex;
    gap: 8px;
}

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

.view-btn:hover {
    border-color: var(--primary-light);
    color: var(--primary);
}

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

/* ===== Products Grid ===== */
.products-section {
    padding: 20px 0 60px;
}

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

.product-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

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

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

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

.product-image-placeholder {
    font-size: 64px;
    opacity: 0.5;
}

.product-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    border-radius: 20px;
    background: var(--accent);
    color: white;
}

.product-badge.bestseller {
    background: var(--success);
}

.product-badge.new {
    background: var(--primary);
}

.product-content {
    padding: 20px;
}

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

.product-title {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-specs {
    display: flex;
    gap: 16px;
    margin-bottom: 12px;
    font-size: 13px;
    color: var(--text-light);
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 16px;
}

.stars {
    color: var(--accent);
    font-size: 14px;
}

.rating-count {
    font-size: 13px;
    color: var(--text-muted);
}

.product-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 16px;
}

.price-current {
    font-size: 24px;
    font-weight: 700;
    color: var(--text);
}

.price-original {
    font-size: 14px;
    color: var(--text-muted);
    text-decoration: line-through;
}

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

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

.btn-compare {
    padding: 10px;
    flex: 0 0 auto;
}

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

/* ===== Products Table ===== */
.products-table-container {
    overflow-x: auto;
}

.products-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
}

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

.products-table th {
    background: var(--background);
    font-size: 13px;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.products-table td {
    font-size: 14px;
}

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

.products-table tr:hover td {
    background: var(--background);
}

.table-product-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.table-product-image {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-sm);
    background: var(--background);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.table-product-name {
    font-weight: 600;
}

/* ===== No Results ===== */
.no-results {
    text-align: center;
    padding: 60px 20px;
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.no-results p {
    font-size: 16px;
    color: var(--text-light);
    margin-bottom: 20px;
}

/* ===== Quiz Section ===== */
.quiz-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
}

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

.quiz-header {
    text-align: center;
    margin-bottom: 32px;
}

.quiz-header h2 {
    font-size: 28px;
    margin-bottom: 8px;
}

.quiz-header p {
    color: var(--text-light);
}

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

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

.progress-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 20%;
}

.progress-text {
    font-size: 13px;
    color: var(--text-light);
}

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

.quiz-question h3 {
    font-size: 20px;
    margin-bottom: 20px;
}

.quiz-options {
    display: grid;
    gap: 12px;
}

.quiz-option {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: var(--background);
    border: 2px solid transparent;
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition);
}

.quiz-option:hover {
    border-color: var(--primary-light);
}

.quiz-option.selected {
    border-color: var(--primary);
    background: rgba(37, 99, 235, 0.05);
}

.quiz-option-icon {
    font-size: 24px;
}

.quiz-option-text {
    font-weight: 500;
}

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

.quiz-results {
    text-align: center;
}

.quiz-results h3 {
    font-size: 24px;
    margin-bottom: 16px;
}

.quiz-results p {
    color: var(--text-light);
    margin-bottom: 32px;
}

.quiz-recommendations {
    display: grid;
    gap: 16px;
    margin-bottom: 24px;
}

/* ===== Compare Section ===== */
.compare-section {
    padding: 80px 0;
}

.compare-container {
    min-height: 200px;
}

.compare-empty {
    text-align: center;
    padding: 60px 20px;
    background: var(--surface);
    border-radius: var(--radius-lg);
    border: 2px dashed var(--border);
}

.compare-empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.compare-empty p {
    color: var(--text-light);
    margin-bottom: 8px;
}

.compare-hint {
    font-size: 14px;
    color: var(--text-muted);
}

.compare-table-container {
    overflow-x: auto;
}

.compare-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
}

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

.compare-table th:first-child,
.compare-table td:first-child {
    text-align: left;
    background: var(--background);
    font-weight: 600;
    min-width: 140px;
}

.compare-table th {
    background: var(--background);
    font-size: 13px;
    font-weight: 600;
}

.compare-product-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.compare-product-image {
    width: 80px;
    height: 80px;
    border-radius: var(--radius);
    background: var(--surface);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.compare-product-name {
    font-size: 14px;
    font-weight: 600;
}

.compare-remove-btn {
    padding: 4px 8px;
    font-size: 12px;
    background: var(--error);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}

.compare-remove-btn:hover {
    background: #dc2626;
}

.compare-actions {
    text-align: center;
    margin-top: 24px;
}

.compare-highlight {
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary);
    font-weight: 600;
}

/* ===== Features Section ===== */
.features-section {
    padding: 80px 0;
    background: var(--surface);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.feature-card {
    text-align: center;
    padding: 32px 24px;
    background: var(--background);
    border-radius: var(--radius-lg);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.feature-icon {
    font-size: 40px;
    margin-bottom: 16px;
}

.feature-card h3 {
    font-size: 18px;
    margin-bottom: 8px;
}

.feature-card p {
    font-size: 14px;
    color: var(--text-light);
}

/* ===== Guide Section ===== */
.guide-section {
    padding: 80px 0;
}

.guide-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.guide-card {
    padding: 28px;
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.guide-card h3 {
    font-size: 18px;
    margin-bottom: 12px;
}

.guide-card p {
    font-size: 14px;
    color: var(--text-light);
    line-height: 1.7;
}

/* ===== SEO Section ===== */
.seo-section {
    padding: 80px 0;
    background: var(--surface);
}

.seo-content {
    max-width: 900px;
    margin: 0 auto;
}

.seo-content h2 {
    font-size: 32px;
    margin-bottom: 24px;
    text-align: center;
}

.seo-content h3 {
    font-size: 20px;
    margin: 32px 0 16px;
    color: var(--text);
}

.seo-content p {
    font-size: 15px;
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 16px;
}

.seo-content a {
    color: var(--primary);
    text-decoration: underline;
}

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

/* ===== Footer ===== */
.footer {
    background: #1e293b;
    color: #e2e8f0;
    padding: 60px 0 30px;
}

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

.footer-brand .logo {
    color: white;
    margin-bottom: 16px;
}

.footer-brand .logo-au {
    color: var(--primary-light);
}

.footer-brand p {
    font-size: 14px;
    color: #94a3b8;
    line-height: 1.7;
}

.footer-links h4 {
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
    color: white;
}

.footer-links ul {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    font-size: 14px;
    color: #94a3b8;
    transition: var(--transition);
}

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

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid #334155;
    text-align: center;
}

.affiliate-disclosure {
    font-size: 12px;
    color: #64748b;
    margin-bottom: 12px;
}

.copyright {
    font-size: 14px;
    color: #94a3b8;
}

/* ===== Toast Notification ===== */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    padding: 16px 24px;
    background: var(--text);
    color: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    animation: slideIn 0.3s ease;
}

.toast.hidden {
    display: none;
}

@keyframes slideIn {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 36px;
    }

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

    .hero-stats {
        gap: 24px;
    }

    .nav-list {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        flex-direction: column;
        background: white;
        padding: 20px;
        gap: 16px;
        box-shadow: var(--shadow-lg);
    }

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

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

    .filter-bar {
        flex-direction: column;
    }

    .filter-group {
        width: 100%;
    }

    .view-toggle {
        width: 100%;
        justify-content: center;
    }

    .quiz-container {
        padding: 32px 24px;
    }

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

    .quiz-navigation .btn {
        width: 100%;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .compare-table th,
    .compare-table td {
        min-width: 140px;
        padding: 12px;
    }

    .section-header h2 {
        font-size: 26px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 50px 0;
    }

    .hero h1 {
        font-size: 28px;
    }

    .stat-number {
        font-size: 22px;
    }

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

    .product-actions {
        flex-direction: column;
    }

    .product-actions .btn {
        width: 100%;
    }
}
