/* ============================================================
   ProductPilot.shop — Custom Styles
   Extends Tailwind CSS with custom animations and components
   ============================================================ */

/* ---- Google Fonts ---- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@400;500;600;700;800&display=swap');

/* ---- CSS Variables ---- */
:root {
    --primary: #0F172A;
    --secondary: #2563EB;
    --accent: #F59E0B;
    --bg: #FFFFFF;
    --bg-soft: #F8FAFC;
    --text: #1E293B;
    --text-muted: #64748B;
    --border: #E2E8F0;
    --gradient-start: #2563EB;
    --gradient-end: #7C3AED;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.1);
    --shadow-xl: 0 20px 60px rgba(0,0,0,0.12);
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
}

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', 'Inter', sans-serif;
    font-weight: 700;
    line-height: 1.2;
}

/* ---- Gradient Text ---- */
.gradient-text {
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ---- Premium Button ---- */
.btn-primary {
    background: linear-gradient(135deg, var(--secondary), #3B82F6);
    color: white;
    padding: 12px 28px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.4);
}
.btn-primary:active {
    transform: translateY(0);
}

.btn-accent {
    background: linear-gradient(135deg, #F59E0B, #F97316);
    color: white;
    padding: 14px 32px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.35);
    text-decoration: none;
}
.btn-accent:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(245, 158, 11, 0.45);
}

.btn-outline {
    background: transparent;
    color: var(--secondary);
    padding: 12px 28px;
    border-radius: 10px;
    font-weight: 600;
    border: 2px solid var(--secondary);
    cursor: pointer;
    transition: all 0.3s ease;
}
.btn-outline:hover {
    background: var(--secondary);
    color: white;
}

/* ---- Amazon Button ---- */
.btn-amazon {
    background: linear-gradient(135deg, #FF9900, #FF6600);
    color: white;
    padding: 16px 36px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 4px 20px rgba(255, 153, 0, 0.35);
    text-decoration: none;
    letter-spacing: 0.02em;
}
.btn-amazon:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 32px rgba(255, 153, 0, 0.5);
}
.btn-amazon:active {
    transform: translateY(-1px);
}
.btn-amazon svg {
    width: 22px;
    height: 22px;
}

/* ---- Card Styles ---- */
.card {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: transparent;
}

.card-glass {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: var(--radius-lg);
}

/* ---- Product Card ---- */
.product-card {
    position: relative;
    overflow: hidden;
}
.product-card .product-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4/3;
    background: var(--bg-soft);
}
.product-card .product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.product-card:hover .product-image img {
    transform: scale(1.08);
}
.product-card .badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
}

/* ---- Badges ---- */
.badge-featured {
    background: linear-gradient(135deg, var(--secondary), #7C3AED);
    color: white;
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}
.badge-trending {
    background: linear-gradient(135deg, #10B981, #059669);
    color: white;
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}
.badge-bestseller {
    background: linear-gradient(135deg, #F59E0B, #F97316);
    color: white;
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* ---- Hero Section ---- */
.hero {
    background: linear-gradient(135deg, #0F172A 0%, #1E293B 50%, #0F172A 100%);
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

/* ---- Pros & Cons ---- */
.pros-list li {
    padding: 8px 0;
    padding-left: 32px;
    position: relative;
}
.pros-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 8px;
    width: 22px;
    height: 22px;
    background: #10B981;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}
.cons-list li {
    padding: 8px 0;
    padding-left: 32px;
    position: relative;
}
.cons-list li::before {
    content: '✕';
    position: absolute;
    left: 0;
    top: 8px;
    width: 22px;
    height: 22px;
    background: #EF4444;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

/* ---- Spec Table ---- */
.spec-table tr:nth-child(even) {
    background: var(--bg-soft);
}
.spec-table td {
    padding: 14px 20px;
    border-bottom: 1px solid var(--border);
}
.spec-table td:first-child {
    font-weight: 600;
    color: var(--primary);
    width: 40%;
}

/* ---- FAQ Accordion ---- */
.faq-item {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
}
.faq-item:hover {
    border-color: var(--secondary);
}
.faq-question {
    padding: 18px 24px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    background: white;
    user-select: none;
    transition: background 0.2s ease;
}
.faq-question:hover {
    background: var(--bg-soft);
}
.faq-question svg {
    transition: transform 0.3s ease;
    flex-shrink: 0;
    margin-left: 16px;
}
.faq-item.active .faq-question svg {
    transform: rotate(180deg);
}
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.faq-item.active .faq-answer {
    max-height: 500px;
}
.faq-answer-inner {
    padding: 0 24px 18px 24px;
    color: var(--text-muted);
    line-height: 1.7;
}

/* ---- Newsletter Section ---- */
.newsletter-section {
    background: linear-gradient(135deg, #0F172A 0%, #1E1B4B 50%, #0F172A 100%);
    position: relative;
    overflow: hidden;
}
.newsletter-section::before {
    content: '';
    position: absolute;
    top: -100px;
    right: -50px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.15) 0%, transparent 70%);
    border-radius: 50%;
}

/* ---- Scroll Animations ---- */
.fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in {
    opacity: 0;
    transition: opacity 0.6s ease;
}
.fade-in.visible {
    opacity: 1;
}

/* ---- Floating Animation ---- */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}
.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* ---- Pulse Glow ---- */
@keyframes pulseGlow {
    0%, 100% { box-shadow: 0 0 20px rgba(37, 99, 235, 0.3); }
    50% { box-shadow: 0 0 40px rgba(37, 99, 235, 0.5); }
}
.pulse-glow {
    animation: pulseGlow 2s ease-in-out infinite;
}

/* ---- Shimmer Loading ---- */
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.shimmer {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

/* ---- Custom Scrollbar ---- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-soft);
}
::-webkit-scrollbar-thumb {
    background: #CBD5E1;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #94A3B8;
}

/* ---- Mobile Navigation ---- */
.mobile-menu {
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.mobile-menu.open {
    transform: translateX(0);
}
.mobile-overlay {
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}
.mobile-overlay.open {
    opacity: 1;
    visibility: visible;
}

/* ---- Image Lightbox ---- */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}
.lightbox.active {
    display: flex;
}
.lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: var(--radius);
}

/* ---- Comparison Table ---- */
.compare-table {
    border-collapse: collapse;
    width: 100%;
}
.compare-table th {
    background: var(--primary);
    color: white;
    padding: 16px 20px;
    font-weight: 600;
    text-align: left;
}
.compare-table td {
    padding: 14px 20px;
    border-bottom: 1px solid var(--border);
}
.compare-table tr:nth-child(even) td {
    background: var(--bg-soft);
}
.compare-table .winner {
    background: rgba(16, 185, 129, 0.08) !important;
    font-weight: 600;
    color: #059669;
}

/* ---- Review Content Styles ---- */
.review-content h2 {
    font-size: 1.5rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    color: var(--primary);
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border);
}
.review-content h3 {
    font-size: 1.25rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: var(--text);
}
.review-content p {
    margin-bottom: 1.25rem;
    line-height: 1.8;
    color: #334155;
}
.review-content ul, .review-content ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}
.review-content li {
    margin-bottom: 0.5rem;
    line-height: 1.7;
}
.review-content img {
    max-width: 100%;
    border-radius: var(--radius);
    margin: 1.5rem 0;
}
.review-content blockquote {
    border-left: 4px solid var(--secondary);
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    background: var(--bg-soft);
    border-radius: 0 var(--radius) var(--radius) 0;
    font-style: italic;
    color: var(--text-muted);
}

/* ---- Section Titles ---- */
.section-title {
    position: relative;
    display: inline-block;
}
.section-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 60px;
    height: 4px;
    background: linear-gradient(135deg, var(--secondary), var(--gradient-end));
    border-radius: 2px;
}

/* ---- Admin Sidebar ---- */
.admin-sidebar {
    background: linear-gradient(180deg, #0F172A 0%, #1E293B 100%);
    transition: width 0.3s ease;
}
.admin-sidebar .nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: #94A3B8;
    border-radius: 8px;
    margin: 2px 12px;
    transition: all 0.2s ease;
    text-decoration: none;
    font-size: 0.9rem;
}
.admin-sidebar .nav-link:hover,
.admin-sidebar .nav-link.active {
    background: rgba(37, 99, 235, 0.15);
    color: #60A5FA;
}
.admin-sidebar .nav-link.active {
    background: rgba(37, 99, 235, 0.2);
    color: white;
}

/* ---- Stat Card ---- */
.stat-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 24px;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
}
.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}
.stat-card.blue::before { background: linear-gradient(90deg, #2563EB, #3B82F6); }
.stat-card.green::before { background: linear-gradient(90deg, #10B981, #34D399); }
.stat-card.amber::before { background: linear-gradient(90deg, #F59E0B, #FBBF24); }
.stat-card.purple::before { background: linear-gradient(90deg, #7C3AED, #8B5CF6); }

/* ---- Responsive ---- */
@media (max-width: 768px) {
    .hero {
        padding-top: 80px;
        padding-bottom: 60px;
    }
    
    .review-content h2 {
        font-size: 1.3rem;
    }
    
    .btn-amazon {
        padding: 14px 24px;
        font-size: 1rem;
        width: 100%;
        justify-content: center;
    }
    
    .spec-table td:first-child {
        width: 45%;
    }
}

/* ---- Print Styles ---- */
@media print {
    .no-print { display: none !important; }
    body { background: white; }
    .card { box-shadow: none; border: 1px solid #ddd; }
}
