/* ============================================================
   INDEMNIZARTE ABOGADOS — Stylesheet compartido
   ============================================================ */

/* === VARIABLES === */
:root {
  --navy: #0d1b36;
  --navy-mid: #1a3360;
  --gold: #c9a227;
  --gold-hover: #b8911f;
  --gold-bg: #fef9ee;
  --green-wa: #25d366;
  --green-wa-dark: #1da851;
  --white: #ffffff;
  --gray-light: #f8fafc;
  --gray-mid: #e2e8f0;
  --text-dark: #111827;
  --text-mid: #4b5563;
  --text-light: #9ca3af;
  --shadow: 0 4px 24px rgba(13, 27, 54, 0.10);
  --shadow-md: 0 8px 40px rgba(13, 27, 54, 0.15);
  --radius: 12px;
  --radius-lg: 20px;
}

/* === RESET & BASE === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  scroll-behavior: smooth;
  overflow-x: hidden; /* previene scroll horizontal en iOS Safari */
}
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text-dark);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
  width: 100%;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

/* === TYPOGRAPHY === */
h1 { font-size: clamp(1.75rem, 5vw, 3rem); font-weight: 800; line-height: 1.15; }
h2 { font-size: clamp(1.5rem, 4vw, 2.25rem); font-weight: 700; line-height: 1.25; }
h3 { font-size: clamp(1.05rem, 3vw, 1.4rem); font-weight: 600; line-height: 1.3; }
p { font-size: 1rem; line-height: 1.7; }

/* === LAYOUT === */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.25rem; }
@media (min-width: 640px) { .container { padding: 0 1.5rem; } }
@media (min-width: 1024px) { .container { padding: 0 2rem; } }
.section { padding: 3rem 0; }
.section-sm { padding: 2rem 0; }
@media (min-width: 768px) {
  .section { padding: 5rem 0; }
  .section-sm { padding: 3rem 0; }
}

/* === BUTTONS === */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 1.75rem;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  text-decoration: none;
  font-family: inherit;
}
.btn-whatsapp {
  background: var(--green-wa);
  color: white;
}
.btn-whatsapp:hover {
  background: var(--green-wa-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}
.btn-gold {
  background: var(--gold);
  color: var(--navy);
}
.btn-gold:hover {
  background: var(--gold-hover);
  transform: translateY(-2px);
}
.btn-outline-white {
  background: transparent;
  color: white;
  border: 2px solid rgba(255,255,255,0.5);
}
.btn-outline-white:hover {
  background: rgba(255,255,255,0.1);
  border-color: white;
}

/* === HEADER === */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  box-shadow: 0 2px 20px rgba(0,0,0,0.2);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1.25rem;
  max-width: 1200px;
  margin: 0 auto;
}
.logo { display: flex; flex-direction: column; line-height: 1.1; }
.logo-main { font-size: 1.25rem; font-weight: 800; color: var(--gold); letter-spacing: -0.5px; }
.logo-sub { font-size: 0.62rem; font-weight: 500; color: rgba(255,255,255,0.6); text-transform: uppercase; letter-spacing: 1.5px; }
.header-nav { display: none; }
@media (min-width: 768px) {
  .header-nav { display: flex; gap: 1.75rem; list-style: none; }
  .header-nav a { color: rgba(255,255,255,0.8); font-size: 0.875rem; font-weight: 500; transition: color 0.2s; }
  .header-nav a:hover { color: var(--gold); }
}
.header-cta .btn { font-size: 0.875rem; padding: 0.6rem 1.25rem; }

/* === HERO === */
.hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  color: white;
  padding: 2.5rem 0 0;
  overflow: hidden;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  align-items: end;
}
@media (min-width: 768px) {
  .hero { padding: 4rem 0 0; }
  .hero-inner { grid-template-columns: 1fr 1fr; min-height: 520px; }
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(201, 162, 39, 0.15);
  border: 1px solid var(--gold);
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.35rem 0.85rem;
  border-radius: 50px;
  margin-bottom: 1.25rem;
  max-width: 100%;
  overflow-wrap: break-word;
  word-break: break-word;
}
.hero-title { color: white; margin-bottom: 1rem; }
.hero-title span { color: var(--gold); }
.hero-sub { font-size: 0.975rem; color: rgba(255,255,255,0.8); margin-bottom: 1.5rem; max-width: 480px; }
.hero-pills { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.5rem; }
.hero-pill {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.9);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.35rem 0.75rem;
  border-radius: 50px;
}
/* CTA hero - full width on mobile */
.hero-content .btn-whatsapp {
  width: 100%;
  justify-content: center;
}
@media (min-width: 480px) {
  .hero-content .btn-whatsapp { width: auto; }
}
.hero-photo { display: flex; justify-content: center; align-items: flex-end; }
.hero-photo img {
  max-height: 420px;
  width: auto;
  border-radius: var(--radius) var(--radius) 0 0;
}
@media (min-width: 768px) {
  .hero-photo img { max-height: 500px; }
}

/* === TRUST BAR === */
.trust-bar { background: var(--gold); padding: 1.5rem 0; }
.trust-bar-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem 1.5rem;
  max-width: 380px;
  margin: 0 auto;
  justify-items: center;
}
/* Fix nested div inside trust-item (structure heredada) */
.trust-item > div { text-align: center; }
@media (min-width: 640px) {
  .trust-bar-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem 3rem;
    max-width: none;
  }
}
.trust-item { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 0.15rem; }
.trust-item-number { font-size: 1.75rem; font-weight: 800; color: var(--navy); line-height: 1; }
.trust-item-label { font-size: 0.7rem; font-weight: 600; color: var(--navy); text-transform: uppercase; letter-spacing: 0.5px; }

/* === SECTION HEADERS === */
.section-tag {
  display: inline-block;
  background: var(--gold-bg);
  color: var(--gold);
  border: 1px solid var(--gold);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 0.3rem 0.85rem;
  border-radius: 50px;
  margin-bottom: 0.85rem;
}
.section-tag.dark {
  background: rgba(201,162,39,0.15);
  border-color: var(--gold);
}
.section-title { color: var(--navy); margin-bottom: 0.75rem; }
.section-sub { color: var(--text-mid); font-size: 1rem; max-width: 580px; }
.section-header { margin-bottom: 2rem; }
@media (min-width: 768px) { .section-header { margin-bottom: 3rem; } }
.section-header.center { text-align: center; }
.section-header.center .section-sub { margin: 0 auto; }

/* === SERVICES GRID === */
.services-grid { display: grid; grid-template-columns: 1fr; gap: 0.875rem; }
@media (min-width: 480px) { .services-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 900px) { .services-grid { grid-template-columns: repeat(4, 1fr); gap: 1.25rem; } }

/* 2-col secondary services → 1 col on mobile */
.services-secondary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.875rem;
  margin-top: 0.875rem;
}
@media (min-width: 600px) {
  .services-secondary { grid-template-columns: 1fr 1fr; gap: 1.25rem; margin-top: 1.25rem; max-width: 640px; }
}

.service-card {
  background: white;
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
  border: 2px solid transparent;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
  text-decoration: none;
  display: block;
  -webkit-tap-highlight-color: rgba(201,162,39,0.15);
}
@media (min-width: 768px) {
  .service-card { padding: 1.75rem 1.5rem; }
}
.service-card:hover,
.service-card:active { border-color: var(--gold); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.service-icon {
  width: 44px; height: 44px;
  background: var(--gold-bg);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}
@media (min-width: 768px) {
  .service-icon { width: 52px; height: 52px; font-size: 1.5rem; margin-bottom: 1rem; }
}
.service-card h3 { color: var(--navy); margin-bottom: 0.4rem; font-size: 0.95rem; }
.service-card p { color: var(--text-mid); font-size: 0.85rem; line-height: 1.5; margin-bottom: 0.75rem; }
.service-link { color: var(--gold); font-size: 0.82rem; font-weight: 600; }

/* === HOW IT WORKS === */
.steps-bg { background: var(--navy); }
.steps-grid { display: grid; grid-template-columns: 1fr; gap: 0; }
@media (min-width: 768px) { .steps-grid { grid-template-columns: repeat(3, 1fr); } }
.step { text-align: center; padding: 1.5rem 1.25rem; }
@media (min-width: 768px) { .step { padding: 2.5rem 2rem; } }
.step-number {
  width: 52px; height: 52px;
  background: var(--gold);
  color: var(--navy);
  font-size: 1.25rem;
  font-weight: 800;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1rem;
}
@media (min-width: 768px) { .step-number { width: 60px; height: 60px; font-size: 1.5rem; } }
.step h3 { color: white; margin-bottom: 0.5rem; font-size: 1rem; }
.step p { color: rgba(255,255,255,0.72); font-size: 0.875rem; }
.flex-center { display: flex; justify-content: center; flex-wrap: wrap; }
.mt-2 { margin-top: 1.5rem; }
.mt-3 { margin-top: 2.5rem; }

/* === MOBILE OVERFLOW PREVENTION — botones en secciones intermedias === */
@media (max-width: 479px) {
  .flex-center .btn,
  .flex-center .btn-expand {
    width: 100%;
    max-width: 380px;
    justify-content: center;
    text-align: center;
  }
}

/* === TAMAÑOS DE BOTÓN POR CONTEXTO === */
/* El inline style fue eliminado — el CSS controla el tamaño */
.hero-content .btn-whatsapp,
.hero-landing .btn-whatsapp { font-size: 1.05rem; }
@media (min-width: 480px) {
  .hero-content .btn-whatsapp,
  .hero-landing .btn-whatsapp { font-size: 1.1rem; padding: 1rem 2rem; }
}
.steps-bg .flex-center .btn,
.about-content .btn { font-size: 1rem; }
@media (min-width: 480px) {
  .steps-bg .flex-center .btn,
  .about-content .btn { font-size: 1.05rem; padding: 1rem 2rem; }
}

/* === TESTIMONIALS === */
.reviews-grid { display: grid; grid-template-columns: 1fr; gap: 1.25rem; }
@media (min-width: 640px) { .reviews-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .reviews-grid { grid-template-columns: repeat(3, 1fr); } }
.review-card {
  background: white;
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow);
  border-left: 4px solid var(--gold);
}
.review-stars { color: #f59e0b; font-size: 1rem; margin-bottom: 0.85rem; letter-spacing: 2px; }
.review-text { color: var(--text-mid); font-size: 0.92rem; line-height: 1.65; margin-bottom: 1.25rem; font-style: italic; }
.review-author { display: flex; align-items: center; gap: 0.75rem; }
.review-avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--navy);
  display: flex; align-items: center; justify-content: center;
  color: white; font-weight: 700; font-size: 1rem;
  flex-shrink: 0;
  overflow: hidden;
}
.review-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.review-name { font-weight: 700; font-size: 0.875rem; color: var(--navy); }
.review-case { font-size: 0.78rem; color: var(--text-light); }
.review-source { display: flex; align-items: center; gap: 0.35rem; font-size: 0.72rem; color: var(--text-light); margin-top: 0.4rem; }
.google-dot { width: 8px; height: 8px; border-radius: 50%; background: #4285f4; display: inline-block; flex-shrink: 0; }

/* Expand reviews */
.btn-expand {
  background: white;
  color: var(--navy);
  border: 2px solid var(--navy);
  padding: 0.75rem 2rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
}
.btn-expand:hover { background: var(--navy); color: white; }

/* === FAQ === */
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--gray-mid); }
.faq-item:first-child { border-top: 1px solid var(--gray-mid); }
.faq-question {
  width: 100%; text-align: left;
  background: none; border: none;
  padding: 1.25rem 0;
  display: flex; justify-content: space-between; align-items: center;
  gap: 1rem;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.975rem; font-weight: 600;
  color: var(--navy);
  transition: color 0.2s;
}
.faq-question:hover { color: var(--gold); }
.faq-icon {
  width: 28px; height: 28px;
  background: var(--gold-bg);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: transform 0.3s ease;
  font-size: 1.1rem; color: var(--gold); font-weight: 700;
  line-height: 1;
}
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.35s ease; }
.faq-item.open .faq-answer { max-height: 400px; }
.faq-answer-inner { padding: 0 0 1.25rem; color: var(--text-mid); font-size: 0.92rem; line-height: 1.75; }

/* === ABOUT === */
.about-grid { display: grid; grid-template-columns: 1fr; gap: 3rem; align-items: center; }
@media (min-width: 768px) { .about-grid { grid-template-columns: 1fr 1fr; } }
.about-photo-wrap { position: relative; }
.about-badge {
  position: absolute;
  bottom: -1rem; right: 0;
  background: var(--gold);
  color: var(--navy);
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius);
  text-align: center;
  box-shadow: var(--shadow);
}
.about-badge-number { font-size: 1.75rem; font-weight: 800; line-height: 1; }
.about-badge-label { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; }
.about-highlights { list-style: none; display: flex; flex-direction: column; gap: 0.75rem; margin-bottom: 2rem; }
.about-highlights li { display: flex; align-items: flex-start; gap: 0.75rem; font-size: 0.925rem; color: var(--text-mid); }
.check {
  width: 22px; height: 22px;
  background: var(--green-wa);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; margin-top: 1px;
}
.check svg { width: 12px; height: 12px; }

/* === CTA FINAL === */
.cta-final {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  text-align: center;
  padding: 5rem 0;
}
.cta-final h2 { color: white; margin-bottom: 1rem; }
.cta-final p { color: rgba(255,255,255,0.75); margin-bottom: 1.5rem; font-size: 1rem; }
.cta-final .btn-whatsapp {
  font-size: 1rem;
  padding: 1rem 1.75rem;
  width: 100%;
  max-width: 380px;
  justify-content: center;
}
@media (min-width: 480px) {
  .cta-final .btn-whatsapp { font-size: 1.1rem; padding: 1.1rem 2.5rem; width: auto; max-width: none; }
}
.cta-disclaimer { font-size: 0.78rem; color: rgba(255,255,255,0.45); margin-top: 1rem; }

/* === FOOTER === */
.footer { background: #060d1a; color: rgba(255,255,255,0.65); padding: 3rem 0 1.5rem; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 2.5rem; margin-bottom: 2.5rem; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.footer-brand p { font-size: 0.85rem; margin-top: 0.75rem; line-height: 1.7; color: rgba(255,255,255,0.5); }
.footer-heading { color: white; font-weight: 700; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 1rem; }
.footer-links { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; }
.footer-links a { font-size: 0.85rem; color: rgba(255,255,255,0.55); transition: color 0.2s; }
.footer-links a:hover { color: var(--gold); }
.footer-contact-item { display: flex; align-items: flex-start; gap: 0.6rem; font-size: 0.85rem; margin-bottom: 0.75rem; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 1.5rem;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 0.75rem;
}
.footer-bottom p { font-size: 0.78rem; color: rgba(255,255,255,0.35); }

/* === FLOATING WHATSAPP === */
.whatsapp-float { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 999; }
.whatsapp-float a {
  display: flex; align-items: center; gap: 0.6rem;
  background: var(--green-wa);
  color: white;
  padding: 0.9rem 1.35rem 0.9rem 1rem;
  border-radius: 50px;
  font-size: 0.875rem; font-weight: 700;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.5);
  transition: all 0.2s;
  animation: wa-pulse 2.5s ease infinite;
}
.whatsapp-float a:hover { background: var(--green-wa-dark); transform: scale(1.05); animation: none; }
.whatsapp-float-text { display: none; }
@media (min-width: 640px) { .whatsapp-float-text { display: inline; } }
@keyframes wa-pulse {
  0%, 100% { box-shadow: 0 4px 20px rgba(37, 211, 102, 0.5); }
  50% { box-shadow: 0 4px 32px rgba(37, 211, 102, 0.8); }
}

/* === LANDING HERO (variante sin foto) === */
.hero-landing {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  padding: 2.5rem 0;
  text-align: center;
  color: white;
  overflow: hidden; /* evita que badge o botones desborden en mobile */
}
@media (min-width: 768px) { .hero-landing { padding: 4.5rem 0; } }
.hero-landing h1 { color: white; margin-bottom: 1rem; }
.hero-landing h1 span { color: var(--gold); }
.hero-landing p { color: rgba(255,255,255,0.78); font-size: 0.975rem; max-width: 600px; margin: 0 auto 1.5rem; }
.hero-landing .btn-whatsapp { width: 100%; justify-content: center; max-width: 360px; }
@media (min-width: 480px) { .hero-landing .btn-whatsapp { width: auto; } }

/* === PROBLEM / SOLUTION 2COL === */
.problem-grid { display: grid; grid-template-columns: 1fr; gap: 2.5rem; }
@media (min-width: 768px) { .problem-grid { grid-template-columns: 1fr 1fr; } }
.problem-list { list-style: none; display: flex; flex-direction: column; gap: 1rem; }
.problem-list li { display: flex; align-items: flex-start; gap: 0.85rem; font-size: 0.95rem; color: var(--text-mid); }
.problem-icon { font-size: 1.25rem; flex-shrink: 0; margin-top: 1px; }

/* === BREADCRUMBS === */
.breadcrumbs { padding: 0.75rem 0; background: var(--gray-light); }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 0.3rem; list-style: none; font-size: 0.8rem; color: var(--text-light); }
.breadcrumbs li + li::before { content: '›'; margin-right: 0.3rem; }
.breadcrumbs a { color: var(--text-light); }
.breadcrumbs a:hover { color: var(--gold); }
.breadcrumbs .current { color: var(--text-mid); font-weight: 500; }

/* === CALCULADORA === */
.calc-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  box-shadow: var(--shadow-md);
  max-width: 640px;
  margin: 0 auto;
}
.calc-card h3 { color: var(--navy); margin-bottom: 1.75rem; text-align: center; }
.form-group { margin-bottom: 1.5rem; }
.form-group label { display: block; font-weight: 600; font-size: 0.9rem; color: var(--navy); margin-bottom: 0.5rem; }
.form-group input, .form-group select {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 2px solid var(--gray-mid);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 1rem;
  color: var(--text-dark);
  transition: border-color 0.2s;
  background: white;
}
.form-group input:focus, .form-group select:focus {
  outline: none;
  border-color: var(--gold);
}
.form-hint { font-size: 0.8rem; color: var(--text-light); margin-top: 0.35rem; }
.calc-result {
  background: var(--navy);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  margin-top: 2rem;
  display: none;
}
.calc-result.visible { display: block; }
.calc-result-label { color: rgba(255,255,255,0.7); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.5rem; }
.calc-result-amount { color: var(--gold); font-size: 2.25rem; font-weight: 800; margin-bottom: 0.5rem; }
.calc-result-note { color: rgba(255,255,255,0.6); font-size: 0.8rem; margin-bottom: 1.5rem; }

/* === UTILITIES === */
.text-gold { color: var(--gold); }
.text-navy { color: var(--navy); }
.bg-light { background: var(--gray-light); }
.bg-navy { background: var(--navy); }
.text-white { color: white; }
.text-center { text-align: center; }
.google-reviews-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  color: var(--text-mid); font-size: 0.875rem;
  margin-top: 2rem; text-decoration: underline;
}
.google-reviews-link:hover { color: var(--navy); }

/* SVG checkmarks inline */
.icon-check-circle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 20px; height: 20px;
  background: var(--green-wa); border-radius: 50%; flex-shrink: 0;
  color: white;
}
