/* ═══════════════════════════════════════════════════════════
   BLUECODE STUDIOS — Landing Restaurantes España
   Extiende styles.css (mismo design system, layout propio)
   ═══════════════════════════════════════════════════════════ */

/* ── NAV: CTA siempre visible (landing de conversión) ── */
.r-nav-cta { display: inline-flex !important; }
.r-cta-short { display: none; }

/* ═══════════ HERO (split: copy + comparador) ═══════════ */
.r-hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-h) + 56px) 24px 88px;
  overflow: hidden;
}
.r-hero-canvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  z-index: 0;
  opacity: 0.55;
}
.r-hero-glow {
  position: absolute;
  top: -25%; left: 18%;
  width: 800px; height: 640px;
  background: radial-gradient(ellipse at center, rgba(61, 116, 242, 0.16), transparent 65%);
  filter: blur(44px);
  z-index: 1;
  pointer-events: none;
}
.r-hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(40px, 5vw, 72px);
  align-items: center;
}
.r-hero-title {
  font-size: clamp(34px, 4.6vw, 58px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.03em;
  text-wrap: balance;
  margin: 0 0 24px;
}
.r-hero-title .line { display: block; overflow: hidden; }
.r-hero-title .line > span { display: inline-block; will-change: transform; }
.r-hero .hero-badge { margin-bottom: 28px; }
.r-hero-desc {
  font-size: clamp(16px, 1.8vw, 18px);
  color: var(--fg-60);
  line-height: 1.7;
  max-width: 560px;
  margin: 0 0 38px;
}
.r-hero-desc strong { color: var(--fg); font-weight: 600; }
.r-hero-btns { justify-content: flex-start; }

/* ── Comparador de comisiones (tickets) ── */
.r-hero-visual {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-width: 420px;
  width: 100%;
  justify-self: end;
}
.r-hero-visual::before {
  content: '';
  position: absolute;
  inset: -20px;
  border-radius: 24px;
  background: linear-gradient(90deg, rgba(36, 54, 107, 0.2), rgba(61, 116, 242, 0.2) 40%, rgba(185, 201, 239, 0.2));
  filter: blur(34px);
  pointer-events: none;
}
.r-ticket {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #0f0f0f;
  padding: 20px 22px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
}
.r-ticket-bad { opacity: 0.82; }
.r-ticket-good {
  border-color: rgba(107, 157, 255, 0.45);
  box-shadow: 0 0 0 1px rgba(107, 157, 255, 0.2) inset, 0 24px 64px rgba(0, 0, 0, 0.55), 0 0 42px rgba(61, 116, 242, 0.14);
}
.r-ticket-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.r-ticket-tag {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-40);
}
.r-tag-good { color: var(--blue-light); }
.r-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  color: #4ade80;
  background: rgba(34, 197, 94, 0.1);
  border-radius: 999px;
  padding: 3px 10px;
}
.r-live-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.r-ticket-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 14.5px;
  color: var(--fg-60);
}
.r-ticket-row b {
  font-family: var(--font-mono);
  font-size: 15.5px;
  font-weight: 500;
  color: var(--fg);
}
.r-neg b { color: #f87171; }
.r-pos b { color: #4ade80; }
.r-ticket-sep {
  height: 1px;
  margin: 8px 0;
  background: repeating-linear-gradient(90deg, var(--border) 0 6px, transparent 6px 12px);
}
.r-ticket-total { font-size: 15px; }
.r-ticket-total span { color: var(--fg); font-weight: 600; }
.r-ticket-total b { font-size: 22px; font-weight: 700; }

/* ═══════════ PROBLEMA ═══════════ */
.r-pain {
  border-top: 1px solid var(--border-subtle);
  text-align: center;
}
.r-pain .section-title { margin-left: auto; margin-right: auto; }
.r-pain-body {
  font-size: clamp(16px, 1.9vw, 19px);
  color: var(--fg-60);
  line-height: 1.75;
  margin: 0 auto 28px;
  max-width: 720px;
}
.r-pain-body strong, .r-pain-list strong { color: var(--fg); font-weight: 600; }
.r-pain-lead {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-40);
  margin: 0 0 18px;
}
.r-pain-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 0 0 48px;
  text-align: left; /* las tarjetas de dolores se leen mejor alineadas */
}
.r-pain-list li {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.005));
  padding: 20px 24px;
}
.r-pain-arrow {
  flex-shrink: 0;
  font-size: 18px;
  line-height: 1.5;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 700;
}
.r-pain-list p {
  font-size: 15.5px;
  color: var(--fg-60);
  line-height: 1.7;
}
.r-transition {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
  text-wrap: balance;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

/* ═══════════ SOLUCIÓN ═══════════ */
.r-solution { border-top: 1px solid var(--border-subtle); }
.r-solution-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  max-width: 980px;
  margin: 0 auto;
}
/* Con 5 tarjetas, la última ocupa el ancho completo */
.r-solution-grid .service-card:nth-child(5):last-child { grid-column: 1 / -1; }

/* ═══════════ NÚMEROS ═══════════ */
.r-stats { border-top: 1px solid var(--border-subtle); }
.r-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.r-stat {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.005));
  padding: 30px 26px;
  transition: border-color 0.35s, transform 0.45s var(--ease-out);
}
.r-stat:hover { border-color: rgba(107, 157, 255, 0.35); transform: translateY(-4px); }
.r-stat-num {
  font-size: clamp(30px, 3.2vw, 42px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 14px;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  white-space: nowrap;
}
.r-stat p {
  font-size: 14px;
  color: var(--fg-60);
  line-height: 1.65;
}

/* ═══════════ CÓMO FUNCIONA ═══════════ */
.r-steps { border-top: 1px solid var(--border-subtle); }
.r-steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  position: relative;
}
.r-step {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.005));
  padding: 28px 26px;
  transition: border-color 0.35s;
}
.r-step:hover { border-color: rgba(107, 157, 255, 0.35); }
.r-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(107, 157, 255, 0.35);
  background: var(--bg);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  color: var(--blue-light);
  margin-bottom: 20px;
  box-shadow: 0 0 20px rgba(61, 116, 242, 0.12);
}
.r-step h3 {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}
.r-step p {
  font-size: 14px;
  color: var(--fg-60);
  line-height: 1.65;
}
.r-steps-cta { text-align: center; margin-top: 48px; }

/* ═══════════ FAQ ═══════════ */
.r-faq { border-top: 1px solid var(--border-subtle); }
.r-faq-list { display: flex; flex-direction: column; gap: 12px; }
.r-faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.005));
  overflow: hidden;
  transition: border-color 0.3s;
}
.r-faq-item.is-open { border-color: rgba(107, 157, 255, 0.35); }
.r-faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  padding: 20px 24px;
  font-family: var(--font-sans);
  font-size: clamp(15px, 1.8vw, 17px);
  font-weight: 600;
  color: var(--fg);
  letter-spacing: -0.01em;
  transition: color 0.25s;
}
.r-faq-q:hover { color: var(--blue-light); }
.r-faq-q svg {
  width: 18px; height: 18px;
  flex-shrink: 0;
  color: var(--blue-light);
  transition: transform 0.35s var(--ease-out);
}
.r-faq-item.is-open .r-faq-q svg { transform: rotate(180deg); }
.r-faq-a {
  height: 0;
  overflow: hidden;
}
.r-faq-a p {
  padding: 0 24px 22px;
  font-size: 15px;
  color: var(--fg-60);
  line-height: 1.7;
  max-width: 700px;
}

/* ═══════════ CTA FINAL: escasez ═══════════ */
.r-scarcity {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 30px;
  font-size: 13.5px;
  color: var(--fg-60);
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 999px;
  padding: 10px 20px;
  text-wrap: balance;
}
.r-scarcity strong { color: var(--fg); font-weight: 600; }

/* ═══════════ FOOTER compacto ═══════════ */
.r-footer { padding: 40px 24px; }
.r-footer .footer-bottom {
  border-top: none;
  padding-top: 0;
  align-items: center;
}

/* ═══════════ RESPONSIVE ═══════════ */
@media (max-width: 1024px) {
  .r-stats-grid { grid-template-columns: repeat(2, 1fr); }
  .r-steps-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 920px) {
  .r-hero { padding-bottom: 72px; }
  .r-hero-grid { grid-template-columns: 1fr; gap: 52px; }
  .r-hero-visual { justify-self: center; max-width: 440px; }
  .r-hero-btns .btn { width: auto; }
}

@media (max-width: 768px) {
  .r-nav-cta { display: inline-flex !important; padding: 9px 14px; font-size: 12.5px; }
  .r-cta-full { display: none; }
  .r-cta-short { display: inline; }
  .nav-logo img { height: 28px; }
  .r-hero-btns .btn { width: 100%; max-width: 360px; }
  .r-pain-list li { padding: 16px 18px; }
  .r-solution-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .r-stats-grid { grid-template-columns: 1fr; }
  .r-steps-grid { grid-template-columns: 1fr; }
  .r-ticket { padding: 16px 18px; }
  .r-faq-q { padding: 16px 18px; }
  .r-faq-a p { padding: 0 18px 18px; }
}

/* ═══════════ REDUCED MOTION ═══════════ */
@media (prefers-reduced-motion: reduce) {
  .r-faq-a { height: auto; }
}
