/* ========== Variables ========== */
:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #10b981;
    --dark: #1e293b;
    --light: #f8fafc;
    --gray: #64748b;
    --gray-light: #e2e8f0;
    --white: #ffffff;
    --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);
    --radius: 12px;
    --transition: all 0.3s ease;
}

/* ========== Reset ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; background: var(--light); color: var(--dark); line-height: 1.6; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; height: auto; }

/* ========== Container ========== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1rem; }

/* ========== Header ========== */
.header {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}
.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}
.logo { display: flex; align-items: center; gap: 0.5rem; font-size: 1.5rem; font-weight: 700; }
.logo-icon { font-size: 1.8rem; }
.logo-text span { color: var(--primary); }

/* Nav */
.nav-list { display: flex; gap: 1.5rem; }
.nav-link { font-weight: 500; color: var(--gray); transition: var(--transition); padding: 0.5rem; }
.nav-link:hover, .nav-link.active { color: var(--primary); }

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}
.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--dark);
    border-radius: 3px;
    transition: var(--transition);
}
.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 6px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -6px); }

/* ========== Hero ========== */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    padding: 4rem 0;
    text-align: center;
}
.hero h1 { font-size: 2.5rem; margin-bottom: 1rem; }
.hero p { font-size: 1.2rem; opacity: 0.9; margin-bottom: 2rem; }
.hero-brands { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.75rem; }
.brand-tag {
    background: rgba(255,255,255,0.2);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.9rem;
    backdrop-filter: blur(10px);
}

/* ========== Filters ========== */
.filters {
    background: var(--white);
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--gray-light);
}
.filters .container { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; }
.filter-group { display: flex; align-items: center; gap: 0.5rem; }
.filter-group label { font-weight: 500; color: var(--gray); }
.filter-group select {
    padding: 0.5rem 1rem;
    border: 1px solid var(--gray-light);
    border-radius: var(--radius);
    font-family: inherit;
    background: var(--white);
    cursor: pointer;
}

/* ========== Main ========== */
.main { padding: 3rem 0; }
.phones-section { margin-bottom: 3rem; }
.section-title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.tier-badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    color: var(--white);
    font-weight: 600;
}
.tier-badge.entry { background: #10b981; }
.tier-badge.mid { background: #3b82f6; }
.tier-badge.high { background: #8b5cf6; }
.tier-badge.flagship { background: linear-gradient(135deg, #f59e0b, #ef4444); }

/* ========== Phone Cards ========== */
.phones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}
.phone-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
}
.phone-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.phone-card img { width: 100%; height: 200px; object-fit: contain; background: var(--light); padding: 1rem; }
.phone-card-body { padding: 1.25rem; }
.phone-card h3 { font-size: 1.1rem; margin-bottom: 0.5rem; }
.phone-brand { color: var(--gray); font-size: 0.85rem; margin-bottom: 0.75rem; }
.phone-rating { display: flex; align-items: center; gap: 0.25rem; margin-bottom: 0.75rem; }
.phone-rating .stars { color: #fbbf24; }
.phone-rating .score { font-weight: 600; margin-left: 0.5rem; }
.phone-specs { font-size: 0.85rem; color: var(--gray); margin-bottom: 1rem; }
.phone-specs span { display: block; margin-bottom: 0.25rem; }
.phone-pros-cons { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; font-size: 0.8rem; margin-bottom: 1rem; }
.pros, .cons { padding: 0.5rem; border-radius: 8px; }
.pros { background: #ecfdf5; color: #065f46; }
.cons { background: #fef2f2; color: #991b1b; }
.pros strong, .cons strong { display: block; margin-bottom: 0.25rem; }
.btn-amazon {
    display: block;
    background: #ff9900;
    color: var(--dark);
    text-align: center;
    padding: 0.75rem;
    border-radius: 8px;
    font-weight: 600;
    transition: var(--transition);
}
.btn-amazon:hover { background: #e68a00; }

/* ========== Footer ========== */
.footer {
    background: var(--dark);
    color: var(--white);
    padding: 2rem 0;
    text-align: center;
}
.footer p { opacity: 0.8; }
.affiliate-notice { font-size: 0.85rem; margin-top: 0.5rem; }

/* ========== Responsive ========== */
@media (max-width: 768px) {
    .hamburger { display: flex; }
    .nav {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--white);
        box-shadow: var(--shadow);
        transform: translateX(-100%);
        transition: var(--transition);
    }
    .nav.active { transform: translateX(0); }
    .nav-list { flex-direction: column; padding: 1rem; }
    .nav-link { padding: 1rem; display: block; border-bottom: 1px solid var(--gray-light); }
    .hero h1 { font-size: 1.75rem; }
    .hero p { font-size: 1rem; }
    .filters .container { flex-direction: column; align-items: stretch; }
    .filter-group { justify-content: space-between; }
    .filter-group select { flex: 1; }
}
