/* =====================================================
   FITHOGAR.ES — Stylesheet Principal
   Mobile-first, sin frameworks externos
   ===================================================== */

/* ── Variables ─────────────────────────────────────── */
:root {
  --primary:       #FF6B35;
  --primary-dark:  #e05a28;
  --secondary:     #2C3E50;
  --secondary-light:#34495e;
  --accent:        #27AE60;
  --warning:       #F39C12;
  --bg:            #F8F9FA;
  --bg-dark:       #eef0f2;
  --white:         #ffffff;
  --text:          #212529;
  --text-muted:    #6C757D;
  --border:        #DEE2E6;
  --shadow-sm:     0 2px 8px rgba(0,0,0,.08);
  --shadow:        0 4px 20px rgba(0,0,0,.12);
  --shadow-lg:     0 8px 40px rgba(0,0,0,.16);
  --radius:        12px;
  --radius-lg:     18px;
  --transition:    all .25s ease;
}

/* ── Reset ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  font-size: 16px;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
ul { list-style: none; }

/* ── Tipografía ────────────────────────────────────── */
h1, h2, h3, h4 {
  font-weight: 700;
  line-height: 1.2;
  color: var(--secondary);
}
h1 { font-size: clamp(1.6rem, 4vw, 2.4rem); }
h2 { font-size: clamp(1.3rem, 3vw, 1.9rem); }
h3 { font-size: clamp(1.1rem, 2.5vw, 1.4rem); }
p  { margin-bottom: 1rem; }

/* ── Utilidades ────────────────────────────────────── */
.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 16px;
}
.section { padding: 56px 0; }
.section-alt { background: var(--bg-dark); }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .4px;
  text-transform: uppercase;
}
.badge-primary  { background: var(--primary);  color: #fff; }
.badge-green    { background: var(--accent);    color: #fff; }
.badge-warning  { background: var(--warning);   color: #fff; }
.badge-gray     { background: var(--border);    color: var(--text-muted); }

/* ── Botones ───────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: .95rem;
  border: none;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}
.btn-primary {
  background: var(--primary);
  color: #fff;
}
.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255,107,53,.35);
  text-decoration: none;
  color: #fff;
}
.btn-amazon {
  background: #FF9900;
  color: #111;
  font-weight: 700;
}
.btn-amazon:hover {
  background: #e68900;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255,153,0,.35);
  text-decoration: none;
  color: #111;
}
.btn-secondary {
  background: var(--secondary);
  color: #fff;
}
.btn-secondary:hover {
  background: var(--secondary-light);
  transform: translateY(-2px);
  text-decoration: none;
  color: #fff;
}
.btn-outline {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: #fff;
  text-decoration: none;
}
.btn-lg { padding: 15px 32px; font-size: 1.05rem; }
.btn-sm { padding: 8px 16px; font-size: .85rem; }
.btn-full { width: 100%; justify-content: center; }

/* ── Header ────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--secondary);
  color: #fff;
  box-shadow: var(--shadow);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-size: 1.3rem;
  font-weight: 800;
  text-decoration: none;
}
.logo span { color: var(--primary); }
.logo-icon {
  width: 36px;
  height: 36px;
  background: var(--primary);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}
.main-nav { display: none; }
.main-nav a {
  color: rgba(255,255,255,.85);
  font-size: .9rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 8px;
  transition: var(--transition);
}
.main-nav a:hover, .main-nav a.active {
  color: #fff;
  background: rgba(255,255,255,.1);
  text-decoration: none;
}
.header-cta { display: none; }
.menu-toggle {
  background: none;
  border: none;
  cursor: pointer;
  color: #fff;
  padding: 8px;
  border-radius: 8px;
}
.mobile-menu {
  display: none;
  background: var(--secondary-light);
  padding: 16px;
}
.mobile-menu.open { display: block; }
.mobile-menu a {
  display: block;
  color: rgba(255,255,255,.9);
  padding: 10px 12px;
  border-radius: 8px;
  font-weight: 500;
  transition: var(--transition);
}
.mobile-menu a:hover {
  background: rgba(255,255,255,.1);
  text-decoration: none;
  color: #fff;
}

/* ── Hero ──────────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, var(--secondary) 0%, #1a252f 100%);
  color: #fff;
  padding: 64px 0;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(255,107,53,.15) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content { position: relative; z-index: 1; }
.hero-tag {
  display: inline-block;
  background: rgba(255,107,53,.2);
  border: 1px solid rgba(255,107,53,.4);
  color: var(--primary);
  padding: 4px 14px;
  border-radius: 20px;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .5px;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.hero h1 {
  color: #fff;
  margin-bottom: 16px;
}
.hero h1 em {
  color: var(--primary);
  font-style: normal;
}
.hero-subtitle {
  font-size: 1.1rem;
  color: rgba(255,255,255,.8);
  max-width: 560px;
  margin-bottom: 28px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 40px; }
.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  max-width: 480px;
}
.hero-stat {
  text-align: center;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius);
  padding: 16px 8px;
}
.hero-stat-value {
  display: block;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--primary);
}
.hero-stat-label {
  font-size: .78rem;
  color: rgba(255,255,255,.65);
}

/* ── Breadcrumb ────────────────────────────────────── */
.breadcrumb {
  padding: 12px 0;
  font-size: .85rem;
  color: var(--text-muted);
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb span { color: var(--text); }

/* ── Section Headers ───────────────────────────────── */
.section-header {
  text-align: center;
  margin-bottom: 40px;
}
.section-header .tag {
  color: var(--primary);
  font-size: .85rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 8px;
  display: block;
}
.section-header h2 { margin-bottom: 12px; }
.section-header p {
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto;
}

/* ── Tarjetas de Producto ──────────────────────────── */
.products-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
.product-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: var(--transition);
  border: 1px solid var(--border);
  position: relative;
}
.product-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
.product-card.top-pick::before {
  content: '⭐ TOP PICK';
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--primary);
  color: #fff;
  font-size: .7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  letter-spacing: .5px;
  z-index: 2;
}
.product-card.best-value::before {
  content: '💰 MEJOR PRECIO';
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--accent);
  color: #fff;
  font-size: .7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  letter-spacing: .5px;
  z-index: 2;
}
.product-img {
  width: 100%;
  height: 220px;
  object-fit: contain;
  background: #f5f5f5;
  padding: 16px;
}
.product-body {
  padding: 20px;
}
.product-category {
  font-size: .75rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 6px;
}
.product-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--secondary);
  margin-bottom: 8px;
  line-height: 1.3;
}
.product-stars {
  color: #F39C12;
  font-size: .95rem;
  margin-bottom: 8px;
}
.product-stars span { color: var(--text-muted); font-size: .82rem; margin-left: 4px; }
.product-price {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--secondary);
  margin-bottom: 12px;
}
.product-price .price-from { font-size: .8rem; font-weight: 400; color: var(--text-muted); }
.product-highlights {
  margin-bottom: 16px;
  padding-left: 0;
}
.product-highlights li {
  font-size: .87rem;
  color: var(--text-muted);
  padding: 3px 0;
  padding-left: 18px;
  position: relative;
}
.product-highlights li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}
.product-footer {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ── Pros/Contras ──────────────────────────────────── */
.pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 16px 0;
}
.pros, .cons {
  background: var(--bg);
  border-radius: var(--radius);
  padding: 14px;
}
.pros h4 { color: var(--accent); font-size: .85rem; margin-bottom: 8px; }
.cons h4 { color: #e74c3c; font-size: .85rem; margin-bottom: 8px; }
.pros li, .cons li {
  font-size: .82rem;
  color: var(--text-muted);
  padding: 3px 0;
  padding-left: 16px;
  position: relative;
}
.pros li::before { content: '+'; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.cons li::before { content: '−'; position: absolute; left: 0; color: #e74c3c; font-weight: 700; }

/* ── Categorías Grid ───────────────────────────────── */
.categories-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}
.category-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 28px;
  text-align: center;
  border: 2px solid var(--border);
  transition: var(--transition);
  text-decoration: none;
  display: block;
}
.category-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateY(-3px);
  text-decoration: none;
}
.category-icon {
  font-size: 3rem;
  margin-bottom: 14px;
  display: block;
}
.category-card h3 {
  color: var(--secondary);
  margin-bottom: 8px;
}
.category-card p {
  color: var(--text-muted);
  font-size: .87rem;
  margin-bottom: 14px;
}
.category-card .btn { margin: 0 auto; }

/* ── Guía de Compra ────────────────────────────────── */
.guide-content {
  max-width: 800px;
  margin: 0 auto;
}
.guide-content h2, .guide-content h3 { margin: 28px 0 12px; }
.guide-content h2:first-child { margin-top: 0; }
.guide-content p { color: var(--text); }
.guide-content ul {
  list-style: disc;
  padding-left: 24px;
  margin-bottom: 1rem;
}
.guide-content ul li {
  padding: 4px 0;
  color: var(--text);
}
.guide-tip {
  background: rgba(255,107,53,.08);
  border-left: 4px solid var(--primary);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 16px 20px;
  margin: 20px 0;
}
.guide-tip strong { color: var(--primary); }

/* ── Tabla comparativa ─────────────────────────────── */
.comparison-table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  margin: 24px 0;
}
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  font-size: .9rem;
}
.comparison-table th {
  background: var(--secondary);
  color: #fff;
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
}
.comparison-table td {
  padding: 11px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}
.comparison-table tr:last-child td { border-bottom: none; }
.comparison-table tr:nth-child(even) td { background: var(--bg); }
.comparison-table .highlight td { background: rgba(255,107,53,.06); font-weight: 600; }
.check { color: var(--accent); font-weight: 700; }
.cross { color: #e74c3c; }

/* ── FAQ ───────────────────────────────────────────── */
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item {
  background: var(--white);
  border-radius: var(--radius);
  margin-bottom: 12px;
  border: 1px solid var(--border);
  overflow: hidden;
}
.faq-question {
  width: 100%;
  text-align: left;
  padding: 18px 20px;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: .95rem;
  color: var(--secondary);
  transition: var(--transition);
}
.faq-question:hover { background: var(--bg); }
.faq-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--bg-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .8rem;
  flex-shrink: 0;
  transition: var(--transition);
}
.faq-item.open .faq-icon { background: var(--primary); color: #fff; transform: rotate(45deg); }
.faq-answer {
  display: none;
  padding: 0 20px 18px;
  color: var(--text-muted);
  font-size: .92rem;
  line-height: 1.7;
}
.faq-item.open .faq-answer { display: block; }

/* ── AdSense placeholders ──────────────────────────── */
.ad-slot {
  background: var(--bg-dark);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  text-align: center;
  color: var(--text-muted);
  font-size: .8rem;
  padding: 20px;
  margin: 24px 0;
}

/* ── CTA Banner ────────────────────────────────────── */
.cta-banner {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 40px 28px;
  text-align: center;
}
.cta-banner h2 { color: #fff; margin-bottom: 12px; }
.cta-banner p { color: rgba(255,255,255,.85); margin-bottom: 24px; }

/* ── Footer ────────────────────────────────────────── */
.site-footer {
  background: var(--secondary);
  color: rgba(255,255,255,.75);
  padding: 48px 0 24px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 40px;
}
.footer-brand .logo { margin-bottom: 12px; font-size: 1.15rem; }
.footer-brand p { font-size: .87rem; line-height: 1.65; }
.footer-col h4 {
  color: #fff;
  font-size: .9rem;
  margin-bottom: 14px;
  letter-spacing: .3px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 8px; }
.footer-col ul a {
  color: rgba(255,255,255,.65);
  font-size: .87rem;
  transition: var(--transition);
}
.footer-col ul a:hover { color: var(--primary); text-decoration: none; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 24px;
  font-size: .8rem;
  text-align: center;
  line-height: 1.7;
}
.footer-bottom a { color: rgba(255,255,255,.6); }
.footer-bottom a:hover { color: var(--primary); }
.affiliate-disclaimer {
  background: rgba(255,255,255,.05);
  border-radius: var(--radius);
  padding: 12px 16px;
  font-size: .78rem;
  color: rgba(255,255,255,.55);
  margin-bottom: 16px;
  text-align: left;
}

/* ── Responsive ────────────────────────────────────── */
@media (min-width: 600px) {
  .products-grid      { grid-template-columns: repeat(2, 1fr); }
  .categories-grid    { grid-template-columns: repeat(2, 1fr); }
  .hero-stats         { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 768px) {
  .main-nav          { display: flex; gap: 4px; }
  .header-cta        { display: flex; }
  .menu-toggle       { display: none; }
  .footer-grid       { grid-template-columns: 2fr 1fr 1fr 1fr; }
}

@media (min-width: 1024px) {
  .products-grid      { grid-template-columns: repeat(3, 1fr); }
  .categories-grid    { grid-template-columns: repeat(3, 1fr); }
  .product-footer     { flex-direction: row; }
}

/* ── Product detail page ───────────────────────────── */
.product-detail-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  margin-bottom: 32px;
}
.product-detail-header {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding: 28px;
}
.product-detail-img {
  width: 100%;
  max-height: 300px;
  object-fit: contain;
  background: #f5f5f5;
  border-radius: var(--radius);
  padding: 20px;
}
.product-rank {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--primary);
  color: #fff;
  font-size: .8rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 10px;
}
.product-detail-price {
  font-size: 2rem;
  font-weight: 800;
  color: var(--secondary);
  margin: 8px 0;
}
.product-specs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 16px 0;
  font-size: .85rem;
}
.spec-item {
  background: var(--bg);
  border-radius: 8px;
  padding: 10px;
}
.spec-label { color: var(--text-muted); font-size: .75rem; margin-bottom: 2px; }
.spec-value { font-weight: 600; color: var(--secondary); }

@media (min-width: 768px) {
  .product-detail-header { grid-template-columns: 280px 1fr; }
}
