/**
 * The Firm - Home Styles
 * Archivo CSS completo para la página principal
 */

/* ============================================
   VARIABLES GLOBALES
   ============================================ */
:root {
  /* Colores principales */
  --tf-primary: #2c3e50;
  --tf-secondary: #7f8c8d;
  --tf-accent: #3498db;
  --tf-accent-hover: #2980b9;
  
  /* Colores de texto */
  --tf-text: #2c3e50;
  --tf-text-light: #7f8c8d;
  --tf-text-white: #ffffff;
  
  /* Backgrounds */
  --tf-bg-white: #ffffff;
  --tf-bg-light: #f8f9fa;
  --tf-bg-dark: #2c3e50;
  
  /* Borders */
  --tf-border: #e1e8ed;
  --tf-border-hover: #3498db;
  
  /* Spacing */
  --tf-spacing-xs: 0.5rem;
  --tf-spacing-sm: 1rem;
  --tf-spacing-md: 2rem;
  --tf-spacing-lg: 4rem;
  --tf-spacing-xl: 6rem;
  
  /* Border radius */
  --tf-radius-sm: 8px;
  --tf-radius-md: 12px;
  --tf-radius-lg: 16px;
  --tf-radius-full: 50%;
  
  /* Shadows */
  --tf-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --tf-shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
  --tf-shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
  
  /* Transitions */
  --tf-transition: all 0.3s ease;
}

/* ============================================
   RESET Y BASE
   ============================================ */
* {
  box-sizing: border-box;
}

.tf-main {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--tf-text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.tf-main p {
  margin: 0 0 1.25rem;
}

.tf-main p:last-child {
  margin-bottom: 0;
}

/* ============================================
   CONTAINERS
   ============================================ */
.tf-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.tf-container--narrow {
  max-width: 800px;
}

/* ============================================
   SECCIONES
   ============================================ */
.tf-section {
  padding: 5rem 0;
}

.tf-section--white {
  background: var(--tf-bg-white);
}

.tf-section--light {
  background: var(--tf-bg-light);
}

.tf-section--dark {
  background: var(--tf-bg-dark) !important;
  color: var(--tf-text-white) !important;
}

.tf-section__title {
  font-size: 2rem;
  font-weight: 600;
  line-height: 1.2;
  color: var(--tf-text);
  margin: 0 0 2rem;
}

.tf-section__title--center {
  text-align: center;
}

.tf-section__title--light {
  color: var(--tf-text-white) !important;
}

.tf-section__content {
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--tf-text-light);
}

.tf-section__content--center {
  text-align: center !important;
}

.tf-section__intro {
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--tf-text-light);
  text-align: center !important;
  max-width: 680px;
  margin-left: auto !important;
  margin-right: auto !important;
}

.tf-section__intro--light {
  color: rgba(255, 255, 255, 0.8) !important;
}

.tf-section__cta {
  text-align: center;
  margin-top: 2.5rem;
}

/* ============================================
   HERO
   ============================================ */
.tf-hero {
  background: linear-gradient(135deg, #f8f9fa 0%, #e8eaf0 100%);
  padding: 6rem 0;
  text-align: center;
}

.tf-hero__title {
  font-size: 3rem;
  font-weight: 600;
  line-height: 1.2;
  color: var(--tf-text);
  margin: 0 0 1.5rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.tf-hero__subtitle {
  font-size: 1.25rem;
  line-height: 1.6;
  color: var(--tf-text-light);
  max-width: 680px;
  margin: 0 auto 2.5rem;
}

.tf-hero__ctas {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ============================================
   BOTONES
   ============================================ */
.tf-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: var(--tf-radius-sm);
  transition: var(--tf-transition);
  cursor: pointer;
  border: none;
  white-space: nowrap;
}

.tf-btn--primary {
  background: var(--tf-accent) !important;
  color: var(--tf-text-white) !important;
  box-shadow: 0 2px 8px rgba(52, 152, 219, 0.2);
}

.tf-btn--primary:hover {
  background: var(--tf-accent-hover) !important;
  color: var(--tf-text-white) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
  text-decoration: none;
}

.tf-btn--secondary {
  background: transparent;
  color: var(--tf-text);
  border: 1px solid var(--tf-border);
}

.tf-btn--secondary:hover {
  background: var(--tf-bg-light);
  border-color: var(--tf-accent);
}

.tf-btn__arrow {
  display: inline-block;
  transition: transform 0.3s ease;
}

.tf-btn:hover .tf-btn__arrow {
  transform: translateX(4px);
}

/* ============================================
   CARDS DE BENEFICIOS
   ============================================ */
.tf-benefits {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 3rem;
}

.tf-benefit-card {
  background: var(--tf-bg-white);
  border: 1px solid var(--tf-border);
  border-radius: var(--tf-radius-md);
  padding: 1.75rem;
  transition: var(--tf-transition);
}

.tf-benefit-card:hover {
  border-color: var(--tf-border-hover);
  box-shadow: var(--tf-shadow-md);
  transform: translateY(-4px);
}

.tf-benefit-card__title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--tf-text);
  margin: 0 0 0.75rem;
  line-height: 1.4;
}

.tf-benefit-card__text {
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--tf-text-light);
  margin: 0;
}

/* ============================================
   LISTAS
   ============================================ */
.tf-list {
  list-style: none;
  padding: 0;
  margin: 2rem 0 0;
}

.tf-list li {
  position: relative;
  padding-left: 2rem;
  margin-bottom: 0.75rem;
  font-size: 1.0625rem;
  color: var(--tf-text-light);
}

.tf-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--tf-accent);
  font-weight: 700;
  font-size: 1.25rem;
}

/* ============================================
   ESTADÍSTICAS
   ============================================ */
.tf-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.tf-stat {
  text-align: center;
  padding: 1.5rem;
}

.tf-stat__number {
  font-size: 3rem;
  font-weight: 700;
  color: var(--tf-accent) !important;
  margin-bottom: 0.5rem;
  line-height: 1;
}

.tf-stat__label {
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.7) !important;
}

/* ============================================
   PASOS (CÓMO ACCEDER)
   ============================================ */
.tf-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.tf-step {
  text-align: center;
  padding: 1.5rem;
}

.tf-step__number {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #e8f4f8 0%, #d0e8f2 100%);
  border-radius: var(--tf-radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--tf-accent);
}

.tf-step__title {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0 0 0.75rem;
  color: var(--tf-text);
}

.tf-step__text {
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--tf-text-light);
  margin: 0;
}

/* ============================================
   FAQS
   ============================================ */
.tf-faqs {
  margin-top: 2rem;
}

.tf-faq {
  border: 1px solid var(--tf-border);
  border-radius: var(--tf-radius-sm);
  margin-bottom: 1rem;
  overflow: hidden;
  background: var(--tf-bg-white);
}

.tf-faq__question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--tf-text);
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: var(--tf-transition);
}

.tf-faq__question:hover {
  background: var(--tf-bg-light);
}

.tf-faq__icon {
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--tf-accent);
  transition: transform 0.3s ease;
  flex-shrink: 0;
  margin-left: 1rem;
}

.tf-faq.is-open .tf-faq__icon {
  transform: rotate(45deg);
}

.tf-faq__answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.tf-faq.is-open .tf-faq__answer {
  max-height: 500px;
}

.tf-faq__answer p {
  padding: 0 1.5rem 1.25rem;
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--tf-text-light);
}

.tf-faq__answer a {
  color: var(--tf-accent);
  text-decoration: none;
}

.tf-faq__answer a:hover {
  text-decoration: underline;
}

/* ============================================
   CIERRE FINAL
   ============================================ */
.tf-final {
  text-align: center;
  padding: 2rem 0;
}

.tf-final__text {
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--tf-text);
  max-width: 680px;
  margin: 0 auto 2rem;
}

.tf-final__ctas {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* Tablet */
@media (max-width: 1024px) {
  .tf-container {
    padding: 0 1.5rem;
  }

  .tf-section {
    padding: 4rem 0;
  }

  .tf-hero {
    padding: 5rem 0;
  }

  .tf-hero__title {
    font-size: 2.5rem;
  }

  .tf-section__title {
    font-size: 1.75rem;
  }

  .tf-benefits {
    grid-template-columns: repeat(2, 1fr);
  }

  .tf-stats {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Móvil */
@media (max-width: 768px) {
  .tf-container {
    padding: 0 1rem;
  }

  .tf-section {
    padding: 3rem 0;
  }

  .tf-hero {
    padding: 4rem 0;
  }

  .tf-hero__title {
    font-size: 2rem;
  }

  .tf-hero__subtitle {
    font-size: 1.125rem;
  }

  .tf-section__title {
    font-size: 1.5rem;
  }

  .tf-section__content,
  .tf-section__intro {
    font-size: 1rem;
  }

  .tf-benefits {
    grid-template-columns: 1fr;
  }

  .tf-stats {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .tf-stat__number {
    font-size: 2.5rem;
  }

  .tf-steps {
    grid-template-columns: 1fr;
  }

  .tf-btn {
    width: 100%;
    justify-content: center;
  }

  .tf-hero__ctas,
  .tf-final__ctas {
    flex-direction: column;
  }

  .tf-list li {
    font-size: 1rem;
  }
}

/* Móvil pequeño */
@media (max-width: 480px) {
  .tf-hero__title {
    font-size: 1.75rem;
  }

  .tf-section__title {
    font-size: 1.375rem;
  }

  .tf-stat__number {
    font-size: 2rem;
  }

  .tf-benefit-card {
    padding: 1.25rem;
  }
}

/* ============================================
   ANIMACIONES
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
  .tf-benefit-card,
  .tf-btn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .tf-faq__answer {
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  }
}

/* Reducir animaciones si el usuario lo prefiere */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}