* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1f2937;
    background-color: #f9fafb;
}

/* Color System */
:root {
    /* Primary Colors */
    --primary-50: #eff6ff;
    --primary-100: #dbeafe;
    --primary-500: #3b82f6;
    --primary-600: #2563eb;
    --primary-700: #1d4ed8;

    /* Secondary Colors */
    --secondary-500: #6366f1;
    --secondary-600: #4f46e5;

    /* Accent Colors */
    --accent-500: #f97316;
    --accent-600: #ea580c;

    /* Success Colors */
    --success-500: #10b981;
    --success-600: #059669;

    /* Warning Colors */
    --warning-500: #f59e0b;
    --warning-600: #d97706;

    /* Error Colors */
    --error-500: #ef4444;
    --error-600: #dc2626;

    /* Neutral Colors */
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;

    /* Spacing System (8px base) */
    --space-1: 8px;
    --space-2: 16px;
    --space-3: 24px;
    --space-4: 32px;
    --space-5: 40px;
    --space-6: 48px;
    --space-8: 64px;
    --space-10: 80px;
    --space-12: 96px;

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Shadows */
    --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);
}

/* Typography */
h1 {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: var(--space-2);
}

h2 {
    font-size: 2rem;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--space-3);
}

h3 {
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--space-2);
}

h4 {
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--space-2);
}

p {
    line-height: 1.5;
    margin-bottom: var(--space-2);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-2);
}

/* Header Styles */
.header {
    background: #f0f0f0;
    color: black;
    padding: var(--space-3) 0;
    box-shadow: var(--shadow-lg);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-4);
}

.logo h1 {
    font-size: 1.875rem;
    margin-bottom: var(--space-1);
}

.logo p {
    font-size: 0.875rem;
    opacity: 0.9;
    margin-bottom: 0;
}

/* Ad Placeholder Styles */
.ad-placeholder {
    background: linear-gradient(45deg, var(--gray-100), var(--gray-200));
    border: 2px dashed var(--gray-300);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-500);
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.header-ad {
    width: 300px;
    height: 80px;
}

.sidebar-ad {
    width: 100%;
    min-width:300px;
    height: 400px;
    margin-bottom: var(--space-4);
}

.footer-ad {
    width: 100%;
    height: 120px;
    margin-bottom: var(--space-4);
}

/* Main Content */
.main-content {
    padding: var(--space-6) 0;
}

.content-wrapper {
  display: grid;
  grid-template-columns: 1fr;
}

/* HERO LAYOUT */
.hero {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-6);
  background: linear-gradient(135deg, var(--primary-50) 0%, var(--secondary-50) 100%);
  border-radius: var(--radius-xl);
}

/* Ad fixed size */
.hero-ad {
  flex: 0 0 300px;
  min-height: 250px;
}

/* Text grows to fill */
.hero-text {
  flex: 1;
  min-width: 280px;
}

/* RESPONSIVE STACKING */
@media (max-width: 768px) {
  .hero {
    flex-direction: column;
    text-align: center;
  }
  .hero-ad {
    margin-bottom: var(--space-3);
  }
}


/* Product Sections */
.product-section {
    margin-bottom: var(--space-10);
}

.section-title {
    color: var(--gray-800);
    border-bottom: 3px solid var(--primary-500);
    padding-bottom: var(--space-2);
    margin-bottom: var(--space-6);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-4);
}

/* Product Cards */
.product-card {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid var(--gray-200);
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-300);
}

.product-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: var(--gray-100);
}

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

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

.product-info {
    padding: var(--space-3);
}

.product-info h3 {
    color: var(--gray-800);
    margin-bottom: var(--space-2);
}

.product-info p {
    color: var(--gray-600);
    font-size: 0.875rem;
    margin-bottom: var(--space-3);
}

.price-range {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--success-600);
    margin-bottom: var(--space-3);
}

/* Affiliate Links */
.affiliate-links {
    display: flex;
    gap: var(--space-2);
}

.btn {
    flex: 1;
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-md);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
    text-align: center;
    transition: all 0.2s ease;
    border: 2px solid transparent;
    display: inline-block;
}

.btn-amazon {
    background: #ff9500;
    color: white;
    border-color: #ff9500;
}

.btn-amazon:hover {
    background: #e6860a;
    border-color: #e6860a;
    transform: translateY(-1px);
}

.btn-ebay {
    background: #0064d2;
    color: white;
    border-color: #0064d2;
}

.btn-ebay:hover {
    background: #0056b3;
    border-color: #0056b3;
    transform: translateY(-1px);
}

/* Affiliate Disclosure */
.disclosure {
    background: var(--warning-50);
    border: 1px solid var(--warning-200);
    border-radius: var(--radius-lg);
}

.disclosure-content h3 {
    color: var(--warning-700);
    margin-bottom: var(--space-2);
}

.disclosure-content p {
    color: var(--warning-700);
    font-size: 0.875rem;
    margin-bottom: 0;
}

/* Footer */
.footer {
    background: var(--gray-800);
    color: var(--gray-300);
    padding: var(--space-8) 0 var(--space-4);
    margin-top: var(--space-10);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-6);
    margin-bottom: var(--space-6);
}

.footer-section h4 {
    color: white;
    margin-bottom: var(--space-3);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: var(--space-1);
}

.footer-section a {
    color: var(--gray-300);
    text-decoration: none;
    font-size: 0.875rem;
    transition: color 0.2s ease;
}

.footer-section a:hover {
    color: var(--primary-400);
}

.footer-bottom {
    border-top: 1px solid var(--gray-700);
    padding-top: var(--space-4);
    text-align: center;
    font-size: 0.875rem;
    color: var(--gray-400);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .content-wrapper {
        grid-template-columns: 250px 1fr;
        gap: var(--space-4);
    }
    
    .header-ad {
        width: 250px;
        height: 70px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 var(--space-2);
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: var(--space-3);
    }
    
    .header-ad {
        width: 100%;
        height: 60px;
    }
    
    .content-wrapper {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        order: 2;
        position: static;
    }
    
    .sidebar-ad {
        height: 200px;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
        gap: var(--space-3);
    }
    
    .affiliate-links {
        flex-direction: column;
    }
    
    /*.hero {
        padding: var(--space-6) var(--space-3);
    }*/
    
    .hero h2 {
        font-size: 1.75rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--space-4);
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2rem;
    }
    
    .logo h1 {
        font-size: 1.5rem;
    }
    
    .hero h2 {
        font-size: 1.5rem;
    }
    
    .section-title {
        font-size: 1.25rem;
    }
    
    .product-info {
        padding: var(--space-2);
    }
    
    .btn {
        padding: var(--space-2);
        font-size: 0.8rem;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles for accessibility */
.btn:focus,
a:focus {
    outline: 2px solid var(--primary-500);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .header-ad,
    .sidebar-ad,
    .footer-ad {
        display: none;
    }
    
    .product-card {
        break-inside: avoid;
    }
}

/* Loading states */
.product-image img {
    background: var(--gray-200);
}

.product-image img[src=""] {
    background: linear-gradient(90deg, var(--gray-200) 25%, var(--gray-300) 50%, var(--gray-200) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Enhanced hover effects */
.product-card {
    position: relative;
    overflow: hidden;
}

.product-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
    z-index: 1;
    pointer-events: none;
}

.product-card:hover::before {
    left: 100%;
}

/* Button group responsive behavior */
@media (max-width: 360px) {
    .affiliate-links {
        gap: var(--space-1);
    }
    
    .btn {
        font-size: 0.75rem;
        padding: var(--space-1) var(--space-2);
    }
}