/* ==========================================================================
   GEOlens — Home
   ========================================================================== */

/* ---------- Hero ---------- */
.hero { position: relative; padding: 72px 0 96px; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, rgba(10, 26, 47, .045) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(10, 26, 47, .045) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
}
.blob { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .55; }
.blob-1 { width: 520px; height: 520px; background: #c9d6ff; top: -160px; left: -120px; }
.blob-2 { width: 460px; height: 460px; background: #e1d9ff; top: 40px; right: -140px; }
.blob-3 { width: 380px; height: 380px; background: #c8f1f6; bottom: -160px; left: 40%; opacity: .45; }

.hero-inner { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(38px, 5.4vw, 64px); font-weight: 800; letter-spacing: -0.035em; margin: 22px 0 20px; }
.hero h1 .line { display: block; overflow: hidden; padding-bottom: .06em; }
.hero h1 .line > span { display: inline-block; }
.hero-lead { font-size: 19px; color: var(--ink-2); max-width: 540px; }

/* Formulario de escaneo */
.scan-form {
  margin-top: 32px;
  display: flex; align-items: center; gap: 8px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow-lg);
  max-width: 580px;
  transition: border-color .2s, box-shadow .2s;
}
.scan-form:focus-within { border-color: rgba(43, 89, 255, .45); box-shadow: var(--shadow-lg), 0 0 0 4px rgba(43, 89, 255, .12); }
.scan-form.has-error { border-color: var(--bad); box-shadow: var(--shadow-lg), 0 0 0 4px rgba(229, 72, 77, .12); }
.scan-input-wrap { flex: 1; display: flex; align-items: center; gap: 10px; padding-left: 12px; min-width: 0; }
.scan-input-wrap svg { width: 20px; height: 20px; color: var(--ink-3); flex-shrink: 0; }
.scan-input { flex: 1; min-width: 0; height: 48px; border: 0; outline: 0; background: transparent; font-size: 16px; font-weight: 500; }
.scan-input::placeholder { color: var(--ink-3); font-weight: 400; }
.scan-error { min-height: 22px; margin-top: 8px; font-size: 14px; color: var(--bad); font-weight: 500; }

/* Selector de tipo de reporte */
.tier-switch { position: relative; display: inline-flex; margin-top: 32px; padding: 4px; border-radius: 14px; background: rgba(255, 255, 255, .7); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.tier-opt { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 16px; border-radius: 10px; font-size: 14px; font-weight: 600; color: var(--ink-2); transition: color .25s; }
.tier-opt svg { width: 14px; height: 14px; }
.tier-opt.is-active { color: #fff; }
.tier-opt .pro-tag { font-size: 10px; font-weight: 800; letter-spacing: .04em; padding: 2px 6px; border-radius: 6px; background: linear-gradient(135deg, #f5a524, #f97316); color: #fff; }
.tier-indicator { position: absolute; z-index: 0; top: 4px; bottom: 4px; left: 4px; border-radius: 10px; background: var(--ink); box-shadow: 0 6px 14px -6px rgba(10, 26, 47, .5); }
.tier-switch + .scan-form { margin-top: 12px; }
.pro-pass { display: none; align-items: center; gap: 12px; margin-top: 10px; max-width: 580px; padding: 6px 6px 6px 18px; background: var(--surface); border: 1px dashed rgba(43, 89, 255, .4); border-radius: 14px; }
.pro-pass.is-visible { display: flex; }
.pro-pass svg { width: 18px; height: 18px; color: var(--brand); flex-shrink: 0; }
.pro-pass input { flex: 1; min-width: 0; height: 40px; border: 0; outline: 0; background: none; font-size: 15px; }
.pro-pass a { font-size: 13px; font-weight: 600; color: var(--brand); white-space: nowrap; padding: 0 10px; }

/* ---------- Planes ---------- */
.plans { display: grid; grid-template-columns: 1fr 1.15fr; gap: 24px; align-items: stretch; max-width: 1000px; margin: 0 auto; }
.plan { position: relative; display: flex; flex-direction: column; padding: 36px; border-radius: var(--radius-lg); background: var(--surface); border: 1px solid var(--line); }
.plan.is-pro { border: 0; background: linear-gradient(var(--surface), var(--surface)) padding-box, linear-gradient(135deg, var(--brand), var(--brand-2), var(--cyan)) border-box; border: 2px solid transparent; box-shadow: var(--shadow-lg); }
.plan-badge { position: absolute; top: -13px; right: 28px; padding: 5px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-2)); }
.plan h3 { font-size: 22px; }
.plan .price { margin: 14px 0 6px; font-size: 40px; font-weight: 800; letter-spacing: -0.03em; }
.plan .price small { font-size: 15px; color: var(--ink-3); font-weight: 600; }
.plan > p { color: var(--ink-2); font-size: 15px; }
.plan ul { list-style: none; padding: 0; margin: 26px 0 30px; display: grid; gap: 12px; flex: 1; }
.plan li { display: flex; gap: 10px; font-size: 15px; }
.plan li svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 3px; color: var(--ok); }
.plan li.off { color: var(--ink-3); }
.plan li.off svg { color: var(--line-2); }
.plan li b { font-weight: 700; }
.plan .engines-mini { display: inline-flex; gap: 4px; margin-left: 4px; vertical-align: middle; }
.plan .engines-mini i { width: 8px; height: 8px; border-radius: 50%; }
.plan-actions { display: grid; gap: 10px; }
.plan-actions .btn { width: 100%; }
@media (max-width: 860px) { .plans { grid-template-columns: 1fr; max-width: 520px; } .plan { padding: 28px; } }

.hero-trust { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 6px; }
.hero-trust span { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; color: var(--ink-2); font-weight: 500; }
.hero-trust svg { width: 16px; height: 16px; color: var(--ok); }

.engines { margin-top: 36px; }
.engines small { display: block; font-size: 12px; font-family: var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 12px; }
.engines-list { display: flex; flex-wrap: wrap; gap: 8px; }
.engine-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 12px; border-radius: 10px;
  background: rgba(255, 255, 255, .7); border: 1px solid var(--line);
  font-size: 13px; font-weight: 600; color: var(--ink-2);
}
.engine-dot { width: 8px; height: 8px; border-radius: 50%; }

/* Visual del hero */
.hero-visual { position: relative; height: 540px; }
.ai-card {
  position: absolute; top: 40px; left: 0; right: 30px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  padding: 22px;
}
.ai-card-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.ai-card-head .dots { display: flex; gap: 6px; }
.ai-card-head .dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); }
.ai-card-head .label { font-family: var(--mono); font-size: 12px; color: var(--ink-3); }
.ai-msg-user {
  margin: 18px 0 16px auto; max-width: 82%;
  padding: 12px 16px; border-radius: 16px 16px 4px 16px;
  background: var(--bg-2); font-size: 14px; font-weight: 500;
}
.ai-msg-bot { display: flex; gap: 12px; }
.ai-avatar { width: 32px; height: 32px; border-radius: 10px; flex-shrink: 0; background: linear-gradient(135deg, var(--brand), var(--brand-2)); display: grid; place-items: center; }
.ai-avatar svg { width: 16px; height: 16px; color: #fff; }
.ai-text { font-size: 14px; color: var(--ink-2); line-height: 1.65; min-height: 112px; }
.ai-text b { color: var(--ink); font-weight: 600; }
.ai-cite {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 18px; height: 18px; padding: 0 5px; margin: 0 2px;
  border-radius: 6px; background: var(--brand-soft); color: var(--brand);
  font-size: 11px; font-weight: 700; vertical-align: 1px;
}
.ai-sources { display: flex; gap: 8px; margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--line); flex-wrap: wrap; }
.ai-source {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 10px 6px 6px; border-radius: 10px;
  border: 1px solid var(--line); font-size: 12px; font-weight: 600; color: var(--ink-2);
}
.ai-source .fav { width: 20px; height: 20px; border-radius: 6px; display: grid; place-items: center; font-size: 10px; font-weight: 800; color: #fff; }
.ai-source.is-you { border-color: rgba(43, 89, 255, .35); background: var(--brand-soft); color: var(--brand); }

.float-card {
  position: absolute; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); padding: 14px 16px;
}
.score-float { right: -10px; bottom: 30px; display: flex; align-items: center; gap: 14px; padding: 16px 20px 16px 16px; }
.score-ring { position: relative; width: 64px; height: 64px; }
.score-ring svg { width: 64px; height: 64px; transform: rotate(-90deg); }
.score-ring .num { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 800; font-size: 19px; }
.score-float small { display: block; font-size: 12px; color: var(--ink-3); font-weight: 500; }
.score-float strong { font-size: 15px; }
.score-float .delta { display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; font-size: 12px; font-weight: 700; color: var(--ok); background: var(--ok-soft); padding: 2px 8px; border-radius: 999px; }

.check-float { left: -24px; bottom: 96px; display: grid; gap: 8px; min-width: 220px; }
.check-row { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 600; }
.check-row .ic { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; }
.check-row .ic svg { width: 13px; height: 13px; }
.check-row .ic.ok { background: var(--ok-soft); color: var(--ok); }
.check-row .ic.warn { background: var(--warn-soft); color: var(--warn); }

.bot-float { top: 0; right: 0; display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 600; padding: 10px 14px; }
.pulse { position: relative; width: 10px; height: 10px; border-radius: 50%; background: var(--ok); }
.pulse::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--ok); opacity: .4; animation: pulse 1.8s ease-out infinite; }
@keyframes pulse { 0% { transform: scale(.6); opacity: .6; } 100% { transform: scale(1.8); opacity: 0; } }

@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { height: 520px; max-width: 560px; margin: 0 auto; width: 100%; }
}
@media (max-width: 560px) {
  .hero { padding: 40px 0 64px; }
  .scan-form { flex-direction: column; align-items: stretch; }
  .scan-input-wrap { padding: 0 8px; }
  .scan-form .btn { width: 100%; }
  .hero-visual { height: 560px; }
  .ai-card { right: 0; top: 52px; }
  .check-float { left: 0; bottom: 120px; }
  .score-float { right: 0; bottom: 10px; }
}

/* ---------- Franja de métricas ---------- */
.stats { padding: 0 0 40px; }
.stats-inner {
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); box-shadow: var(--shadow);
}
.stat { padding: 28px 28px; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat .val { font-size: 36px; font-weight: 800; letter-spacing: -0.03em; }
.stat .lbl { font-size: 14px; color: var(--ink-2); margin-top: 4px; }
@media (max-width: 800px) {
  .stats-inner { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}

/* ---------- Secciones genéricas ---------- */
.section { padding: 110px 0; }
.section-head { max-width: 720px; margin-bottom: 56px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head h2 { font-size: clamp(30px, 3.8vw, 46px); font-weight: 800; letter-spacing: -0.03em; }
.section-head p { margin-top: 16px; font-size: 18px; color: var(--ink-2); }
@media (max-width: 640px) { .section { padding: 72px 0; } }

/* ---------- SEO vs GEO ---------- */
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.compare-card { padding: 36px; border-radius: var(--radius-lg); border: 1px solid var(--line); background: var(--surface); }
.compare-card.is-geo { background: linear-gradient(160deg, #ffffff 0%, #f1f4ff 100%); border-color: rgba(43, 89, 255, .25); box-shadow: var(--shadow); position: relative; overflow: hidden; }
.compare-card .tag { display: inline-block; font-family: var(--mono); font-size: 12px; padding: 4px 10px; border-radius: 8px; background: var(--bg-2); color: var(--ink-2); }
.compare-card.is-geo .tag { background: var(--brand); color: #fff; }
.compare-card h3 { font-size: 24px; margin: 18px 0 10px; }
.compare-card > p { color: var(--ink-2); }
.compare-list { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 14px; }
.compare-list li { display: flex; gap: 12px; font-size: 15px; color: var(--ink-2); }
.compare-list svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 2px; color: var(--ink-3); }
.compare-card.is-geo .compare-list svg { color: var(--brand); }
.compare-card.is-geo .compare-list li { color: var(--ink); }
@media (max-width: 800px) { .compare { grid-template-columns: 1fr; } .compare-card { padding: 28px; } }

/* ---------- Pilares ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pillar {
  position: relative; padding: 30px; border-radius: var(--radius-lg);
  background: var(--surface); border: 1px solid var(--line);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s;
  overflow: hidden;
}
.pillar:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: rgba(43, 89, 255, .25); }
.pillar-icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); margin-bottom: 22px; }
.pillar-icon svg { width: 24px; height: 24px; }
.pillar h3 { font-size: 19px; margin-bottom: 10px; }
.pillar p { font-size: 15px; color: var(--ink-2); }
.pillar .weight { position: absolute; top: 30px; right: 30px; font-family: var(--mono); font-size: 12px; color: var(--ink-3); }
@media (max-width: 960px) { .pillars { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .pillars { grid-template-columns: 1fr; } }

/* ---------- Cómo funciona ---------- */
.steps-wrap { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.steps-line { position: absolute; top: 28px; left: 8%; right: 8%; height: 2px; background: var(--line); }
.steps-line span { position: absolute; inset: 0; background: linear-gradient(90deg, var(--brand), var(--brand-2)); transform-origin: left; transform: scaleX(0); }
.step { position: relative; text-align: center; padding: 0 12px; }
.step-num {
  width: 56px; height: 56px; margin: 0 auto 24px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 800; font-size: 18px;
  background: var(--surface); border: 2px solid var(--line); color: var(--ink-3);
  position: relative; z-index: 1; transition: all .4s var(--ease);
}
.step.is-active .step-num { border-color: var(--brand); color: #fff; background: var(--brand); box-shadow: 0 0 0 6px rgba(43, 89, 255, .12); }
.step h3 { font-size: 20px; margin-bottom: 10px; }
.step p { color: var(--ink-2); font-size: 15px; max-width: 320px; margin: 0 auto; }
@media (max-width: 800px) {
  .steps-wrap { grid-template-columns: 1fr; gap: 40px; }
  .steps-line { display: none; }
}

/* ---------- Preview del reporte ---------- */
.preview-section { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.preview-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 64px; align-items: center; }
.preview-points { list-style: none; padding: 0; margin: 32px 0 36px; display: grid; gap: 20px; }
.preview-points li { display: flex; gap: 16px; }
.preview-points .ic { width: 40px; height: 40px; flex-shrink: 0; border-radius: 12px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; }
.preview-points .ic svg { width: 20px; height: 20px; }
.preview-points h4 { font-size: 16px; margin-bottom: 4px; }
.preview-points p { font-size: 15px; color: var(--ink-2); }

.mock-report {
  border-radius: var(--radius-lg); border: 1px solid var(--line);
  background: var(--bg); padding: 22px; box-shadow: var(--shadow-lg);
}
.mock-top { display: flex; align-items: center; gap: 14px; padding: 18px; background: var(--surface); border-radius: var(--radius); border: 1px solid var(--line); }
.mock-top .score-ring { width: 72px; height: 72px; }
.mock-top .score-ring svg { width: 72px; height: 72px; }
.mock-top h4 { font-size: 16px; }
.mock-top small { color: var(--ink-3); font-size: 13px; }
.mock-grade { margin-left: auto; padding: 6px 12px; border-radius: 10px; background: var(--ok-soft); color: var(--ok); font-weight: 800; }
.mock-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 12px; }
.mock-kpi { padding: 14px; background: var(--surface); border-radius: 14px; border: 1px solid var(--line); }
.mock-kpi small { font-size: 12px; color: var(--ink-3); }
.mock-kpi b { display: block; font-size: 22px; margin-top: 2px; }
.mock-bars { margin-top: 12px; padding: 18px; background: var(--surface); border-radius: var(--radius); border: 1px solid var(--line); display: grid; gap: 14px; }
.mock-bar { display: grid; grid-template-columns: 90px 1fr 34px; align-items: center; gap: 12px; font-size: 13px; font-weight: 600; }
.mock-bar .track { height: 8px; border-radius: 99px; background: var(--bg-2); overflow: hidden; }
.mock-bar .fill { height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--brand), var(--brand-2)); transform-origin: left; }
.mock-bar span:last-child { text-align: right; color: var(--ink-2); }
@media (max-width: 960px) {
  .preview-grid { grid-template-columns: 1fr; gap: 48px; }
}
@media (max-width: 480px) { .mock-row { grid-template-columns: 1fr 1fr; } .mock-row .mock-kpi:last-child { display: none; } }

/* ---------- Testimonios ---------- */
.testimonials { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.testimonial { padding: 28px; border-radius: var(--radius-lg); background: var(--surface); border: 1px solid var(--line); display: flex; flex-direction: column; }
.stars { display: flex; gap: 2px; color: #f5a524; margin-bottom: 16px; }
.stars svg { width: 16px; height: 16px; }
.testimonial blockquote { margin: 0; font-size: 16px; line-height: 1.65; flex: 1; }
.author { display: flex; align-items: center; gap: 12px; margin-top: 24px; }
.author .av { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: #fff; font-size: 14px; }
.author b { display: block; font-size: 14px; }
.author small { font-size: 13px; color: var(--ink-3); }
@media (max-width: 960px) { .testimonials { grid-template-columns: 1fr; max-width: 560px; margin: 0 auto; } }

/* ---------- FAQ ---------- */
.faq { max-width: 820px; margin: 0 auto; display: grid; gap: 12px; }
.faq-item { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; transition: border-color .2s, box-shadow .2s; }
.faq-item.is-open { border-color: rgba(43, 89, 255, .3); box-shadow: var(--shadow); }
.faq-q { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 24px; text-align: left; font-size: 17px; font-weight: 600; }
.faq-q .plus { width: 28px; height: 28px; flex-shrink: 0; border-radius: 8px; background: var(--bg-2); display: grid; place-items: center; transition: transform .3s var(--ease), background .3s; }
.faq-q .plus svg { width: 14px; height: 14px; }
.faq-item.is-open .plus { transform: rotate(45deg); background: var(--brand-soft); color: var(--brand); }
.faq-a { height: 0; overflow: hidden; }
.faq-a p { padding: 0 24px 22px; color: var(--ink-2); }

/* ---------- CTA final ---------- */
.cta-final { padding: 0 0 110px; }
.cta-box {
  position: relative; overflow: hidden;
  padding: 72px 48px; border-radius: 32px; text-align: center;
  background: linear-gradient(135deg, #2b59ff 0%, #5b4dff 55%, #7b61ff 100%);
  color: #fff;
}
.cta-box::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, .08) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, .08) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse at center, #000 20%, transparent 75%);
}
.cta-box > * { position: relative; }
.cta-box h2 { font-size: clamp(30px, 4vw, 48px); font-weight: 800; letter-spacing: -0.03em; }
.cta-box p { margin: 16px auto 0; max-width: 560px; font-size: 18px; color: rgba(255, 255, 255, .82); }
.cta-box .scan-form { margin: 32px auto 0; border-color: transparent; }
.cta-box .scan-error { color: #ffd5d6; }
@media (max-width: 560px) { .cta-box { padding: 48px 20px; border-radius: 24px; } }
