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

:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --accent: #f59e0b;
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #1e293b;
  --text-muted: #64748b;
  --border: #e2e8f0;
  --success: #10b981;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md: 0 4px 6px rgba(0,0,0,.07), 0 2px 4px rgba(0,0,0,.06);
  --shadow-lg: 0 10px 25px rgba(0,0,0,.1);
  --max-width: 1200px;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* === NAVIGATION === */
.nav {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(12px);
  background: rgba(255,255,255,.92);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 64px;
}

.nav-logo {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--primary);
  display: flex; align-items: center; gap: 8px;
  text-decoration: none;
}
.nav-logo:hover { text-decoration: none; }

.nav-logo .icon { font-size: 1.6rem; }

.nav-links {
  display: flex; gap: 24px; list-style: none; align-items: center;
}

.nav-links a {
  color: var(--text-muted);
  font-weight: 500;
  font-size: .925rem;
  transition: color .15s;
  text-decoration: none;
}
.nav-links a:hover { color: var(--primary); text-decoration: none; }

.nav-cta {
  background: var(--primary);
  color: #fff !important;
  padding: 8px 20px;
  border-radius: 50px;
  font-weight: 600;
  transition: background .15s;
}
.nav-cta:hover { background: var(--primary-dark); }

.mobile-menu-btn {
  display: none;
  background: none; border: none;
  font-size: 1.6rem; cursor: pointer;
  color: var(--text);
}

/* === HERO === */
.hero {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #a855f7 100%);
  color: #fff;
  padding: 80px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.hero-inner { max-width: 800px; margin: 0 auto; position: relative; z-index: 1; }

.hero h1 {
  font-size: 3rem;
  font-weight: 900;
  line-height: 1.15;
  margin-bottom: 20px;
  letter-spacing: -.02em;
}

.hero p {
  font-size: 1.2rem;
  opacity: .9;
  margin-bottom: 36px;
  max-width: 600px;
  margin-left: auto; margin-right: auto;
}

.hero-search {
  display: flex; gap: 12px;
  max-width: 500px; margin: 0 auto;
}

.hero-search input {
  flex: 1;
  padding: 14px 20px;
  border-radius: 50px;
  border: 2px solid transparent;
  font-size: 1rem;
  outline: none;
  transition: border-color .2s;
}
.hero-search input:focus { border-color: var(--accent); }

.hero-search button {
  background: var(--accent);
  color: #1e293b;
  border: none;
  padding: 14px 28px;
  border-radius: 50px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s;
}
.hero-search button:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(245,158,11,.4); }

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

.hero-stat { text-align: center; }
.hero-stat .num { font-size: 2rem; font-weight: 900; }
.hero-stat .label { font-size: .85rem; opacity: .75; }

/* === SECTION === */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 64px 24px;
}

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-header h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.section-header p {
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto;
  font-size: 1.05rem;
}

/* === CATEGORY CARDS === */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.cat-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px;
  border: 1px solid var(--border);
  transition: transform .2s, box-shadow .2s;
  text-decoration: none;
  color: var(--text);
  display: block;
}
.cat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  text-decoration: none;
}

.cat-card .icon { font-size: 2.2rem; margin-bottom: 12px; display: block; }
.cat-card h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 8px; }
.cat-card p { color: var(--text-muted); font-size: .9rem; line-height: 1.6; }
.cat-card .count { 
  display: inline-block; margin-top: 12px;
  font-size: .8rem; color: var(--primary);
  background: #eef2ff; padding: 4px 12px;
  border-radius: 50px; font-weight: 600;
}

/* === COMPARISON CARDS === */
.comparison-list {
  display: flex; flex-direction: column; gap: 20px;
}

.compare-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 28px;
  display: grid;
  grid-template-columns: 80px 1fr auto;
  gap: 20px;
  align-items: center;
  transition: box-shadow .2s;
}
.compare-card:hover { box-shadow: var(--shadow-md); }

.compare-rank {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #8b5cf6);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; font-weight: 900;
}
.compare-rank.gold { background: linear-gradient(135deg, #f59e0b, #d97706); }
.compare-rank.silver { background: linear-gradient(135deg, #94a3b8, #64748b); }
.compare-rank.bronze { background: linear-gradient(135deg, #d97706, #b45309); }

.compare-info h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 4px; }
.compare-info h3 a { color: var(--text); }
.compare-info h3 a:hover { color: var(--primary); text-decoration: none; }
.compare-info .tagline { color: var(--text-muted); font-size: .9rem; margin-bottom: 10px; }

.compare-tags {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.compare-tags span {
  font-size: .75rem;
  padding: 3px 10px;
  border-radius: 50px;
  font-weight: 600;
}
.tag-pro { background: #ecfdf5; color: #059669; }
.tag-free { background: #eff6ff; color: #2563eb; }
.tag-bonus { background: #fef3c7; color: #b45309; }

.compare-score {
  text-align: center;
}

.compare-score .score-num {
  font-size: 2rem; font-weight: 900; color: var(--primary);
  line-height: 1;
}

.compare-score .score-label {
  font-size: .75rem; color: var(--text-muted); margin-top: 4px;
}

.compare-cta {
  text-align: right;
}

.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 50px;
  font-weight: 700;
  font-size: .925rem;
  text-decoration: none;
  transition: all .15s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}
.btn-primary:hover { background: var(--primary-dark); text-decoration: none; transform: translateY(-1px); }

.btn-outline {
  border: 2px solid var(--primary);
  color: var(--primary);
  background: transparent;
}
.btn-outline:hover { background: var(--primary); color: #fff; text-decoration: none; }

/* === ARTICLE LIST === */
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 24px;
}

.article-card {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: transform .2s, box-shadow .2s;
}
.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.article-card-img {
  height: 180px;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem;
}

.article-card-body { padding: 20px; }

.article-card-body .date {
  font-size: .8rem; color: var(--text-muted);
  margin-bottom: 8px;
}

.article-card-body h3 {
  font-size: 1.1rem; font-weight: 700;
  margin-bottom: 8px; line-height: 1.4;
}
.article-card-body h3 a { color: var(--text); }
.article-card-body h3 a:hover { color: var(--primary); text-decoration: none; }

.article-card-body p {
  color: var(--text-muted); font-size: .9rem;
  line-height: 1.6;
}

/* === NEWSLETTER === */
.newsletter {
  background: linear-gradient(135deg, #1e293b, #334155);
  color: #fff;
  padding: 64px 24px;
  text-align: center;
}

.newsletter-inner { max-width: 560px; margin: 0 auto; }

.newsletter h2 { font-size: 1.8rem; font-weight: 800; margin-bottom: 12px; }
.newsletter p { opacity: .8; margin-bottom: 28px; }

.newsletter-form {
  display: flex; gap: 12px;
}
.newsletter-form input {
  flex: 1;
  padding: 14px 20px;
  border-radius: 50px;
  border: none;
  font-size: 1rem;
  outline: none;
}
.newsletter-form button {
  padding: 14px 28px;
  border-radius: 50px;
  border: none;
  background: var(--accent);
  color: #1e293b;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
}

/* === FOOTER === */
.footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 48px 24px 32px;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 36px;
}

.footer-col h4 {
  font-size: .9rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .05em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 8px; }
.footer-col ul li a {
  color: var(--text);
  font-size: .9rem;
  text-decoration: none;
}
.footer-col ul li a:hover { color: var(--primary); }

.footer-bottom {
  max-width: var(--max-width);
  margin: 36px auto 0;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex; justify-content: space-between;
  align-items: center; flex-wrap: wrap; gap: 12px;
  font-size: .85rem; color: var(--text-muted);
}

.disclaimer {
  font-size: .78rem; color: var(--text-muted);
  line-height: 1.6; margin-top: 8px;
}

/* === BREADCRUMB === */
.breadcrumb {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 16px 24px;
  font-size: .85rem;
  color: var(--text-muted);
}

.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb span { color: var(--text); }

/* === ARTICLE PAGE === */
.article-container {
  max-width: 780px;
  margin: 0 auto;
  padding: 48px 24px 64px;
}

.article-meta {
  display: flex; gap: 16px; align-items: center;
  margin-bottom: 24px; flex-wrap: wrap;
  font-size: .9rem; color: var(--text-muted);
}

.article-meta .tag {
  background: #eef2ff; color: var(--primary);
  padding: 3px 12px; border-radius: 50px;
  font-weight: 600; font-size: .8rem;
}

.article-container h1 {
  font-size: 2.4rem; font-weight: 900;
  line-height: 1.2; margin-bottom: 16px;
}

.article-container .lead {
  font-size: 1.15rem; color: var(--text-muted);
  margin-bottom: 32px; line-height: 1.7;
}

.article-container h2 {
  font-size: 1.5rem; font-weight: 800;
  margin: 40px 0 16px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.article-container h3 {
  font-size: 1.15rem; font-weight: 700;
  margin: 28px 0 12px;
}

.article-container p {
  margin-bottom: 16px;
  line-height: 1.8;
}

.article-container ul, .article-container ol {
  margin-bottom: 20px; padding-left: 24px;
}
.article-container li { margin-bottom: 8px; line-height: 1.7; }

/* === COMPARISON TABLE === */
.compare-table {
  width: 100%; border-collapse: collapse;
  margin: 24px 0 32px;
  font-size: .9rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.compare-table thead { background: #f1f5f9; }
.compare-table th {
  text-align: left; padding: 14px 16px;
  font-weight: 700; font-size: .85rem;
  text-transform: uppercase; letter-spacing: .03em;
  color: var(--text-muted);
}

.compare-table td {
  padding: 14px 16px;
  border-top: 1px solid var(--border);
}

.compare-table tbody tr:hover { background: #f8fafc; }
.compare-table .highlight { background: #fef3c7; }

.check { color: var(--success); font-weight: 700; }
.cross { color: #ef4444; }

/* === TOP PICK BOX === */
.top-pick {
  background: linear-gradient(135deg, #fef3c7, #fef9c3);
  border: 2px solid #f59e0b;
  border-radius: var(--radius);
  padding: 24px;
  margin: 24px 0;
}

.top-pick .badge {
  display: inline-block;
  background: #f59e0b;
  color: #fff;
  padding: 4px 14px;
  border-radius: 50px;
  font-size: .8rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.top-pick h3 { margin-top: 0 !important; }

/* === CTA BOX === */
.cta-box {
  background: var(--surface);
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  padding: 28px;
  text-align: center;
  margin: 32px 0;
}

.cta-box h3 { margin-top: 0; font-size: 1.25rem; }
.cta-box p { color: var(--text-muted); margin-bottom: 16px; }

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .hero h1 { font-size: 2rem; }
  .hero p { font-size: 1rem; }
  .hero-stats { gap: 24px; }
  
  .nav-links { display: none; }
  .mobile-menu-btn { display: block; }
  
  .compare-card {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .compare-rank { margin: 0 auto; }
  .compare-cta { text-align: center; }
  .compare-score { margin: 0 auto; }
  
  .article-container h1 { font-size: 1.8rem; }
  
  .newsletter-form { flex-direction: column; }
  .hero-search { flex-direction: column; }
  
  .compare-table { font-size: .8rem; }
  .compare-table th, .compare-table td { padding: 10px 12px; }
  
  .footer-inner { grid-template-columns: 1fr 1fr; }
}
