/**
 * Grupo FAM - Estilos dedicados para la Línea de Tiempo Histórica (20 Hitos)
 */

.fam-timeline-section {
  position: relative;
  padding: 80px 0;
  background: #fdfdfd;
}

.fam-timeline-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

.fam-timeline-header {
  margin-bottom: 56px;
}

.fam-timeline-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #a37a3f;
  background: rgba(163, 122, 63, 0.08);
  border: 1px solid rgba(163, 122, 63, 0.25);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.fam-timeline-title {
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 700;
  color: #11162b;
  margin: 0 0 16px 0;
  letter-spacing: -0.02em;
}

.fam-timeline-subtitle {
  font-size: 16px;
  line-height: 1.6;
  color: #555f7c;
  max-width: 760px;
  margin: 0;
}

/* Controles de filtro o eras */
.fam-timeline-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 40px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(17, 22, 43, 0.08);
}

.fam-timeline-filter-btn {
  background: #f4f6fa;
  border: 1px solid rgba(17, 22, 43, 0.08);
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: #4b5570;
  cursor: pointer;
  transition: all 0.2s ease;
}

.fam-timeline-filter-btn:hover,
.fam-timeline-filter-btn.active {
  background: #11162b;
  color: #ffffff;
  border-color: #11162b;
}

/* Árbol de la Línea de Tiempo */
.fam-timeline-tree {
  position: relative;
  padding: 20px 0;
}

.fam-timeline-tree::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 90px;
  width: 2px;
  background: linear-gradient(180deg, rgba(163, 122, 63, 0.6) 0%, rgba(17, 22, 43, 0.15) 50%, rgba(163, 122, 63, 0.6) 100%);
}

@media (max-width: 640px) {
  .fam-timeline-tree::before {
    left: 24px;
  }
}

.fam-timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 32px;
  margin-bottom: 36px;
  align-items: start;
}

@media (max-width: 640px) {
  .fam-timeline-item {
    grid-template-columns: 1fr;
    gap: 12px;
    padding-left: 48px;
  }
}

.fam-timeline-year-col {
  text-align: right;
  position: relative;
}

@media (max-width: 640px) {
  .fam-timeline-year-col {
    text-align: left;
  }
}

.fam-timeline-year-badge {
  display: inline-block;
  font-size: 16px;
  font-weight: 800;
  color: #11162b;
  background: #ffffff;
  padding: 4px 10px;
  border-radius: 6px;
  border: 1px solid rgba(17, 22, 43, 0.12);
  letter-spacing: -0.01em;
  box-shadow: 0 2px 6px rgba(17, 22, 43, 0.04);
}

.fam-timeline-node {
  position: absolute;
  top: 10px;
  left: 90px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #a37a3f;
  border: 3px solid #ffffff;
  transform: translateX(-50%);
  box-shadow: 0 0 0 2px rgba(163, 122, 63, 0.3);
  z-index: 2;
  transition: transform 0.2s ease, background 0.2s ease;
}

@media (max-width: 640px) {
  .fam-timeline-node {
    left: 24px;
    top: 6px;
  }
}

.fam-timeline-item:hover .fam-timeline-node {
  transform: translateX(-50%) scale(1.3);
  background: #11162b;
  box-shadow: 0 0 0 3px rgba(17, 22, 43, 0.25);
}

.fam-timeline-card {
  background: #ffffff;
  border: 1px solid rgba(17, 22, 43, 0.08);
  border-radius: 12px;
  padding: 22px 26px;
  box-shadow: 0 4px 16px rgba(17, 22, 43, 0.03);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.fam-timeline-card:hover {
  border-color: rgba(163, 122, 63, 0.4);
  box-shadow: 0 10px 24px rgba(17, 22, 43, 0.07);
  transform: translateY(-2px);
}

.fam-timeline-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.fam-timeline-card-title {
  font-size: 17px;
  font-weight: 700;
  color: #11162b;
  margin: 0;
  line-height: 1.35;
}

.fam-timeline-card-tag {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: #6a7490;
  background: #f4f6fa;
  padding: 3px 8px;
  border-radius: 4px;
  white-space: nowrap;
}

.fam-timeline-card-text {
  font-size: 14px;
  line-height: 1.65;
  color: #4b5570;
  margin: 0;
}
